This site requires JavaScript, please enable it in your browser!
Greenfoot back

Report as inappropriate.

edparrish
edparrish presents ...

2011/8/10

Dialogs

This project shows how to use Java dialogs created with JOptionPane in your Greenfoot scenarios. Java dialogs provide an easy way to get user input, such as a name, for use in a scenario.

There are three main types of dialogs supported:
- input dialogs
- confirmation dialogs
- message dialogs

You will see all three used in this scenario.

Instructions:
1. Run the scenario.
2. When the phone rings, answer it by clicking the image.

8402 views / 18 in the last 7 days

5 votes | 0 in the last 7 days

Tags: demo with-source gui cabrillo

open in greenfoot
Your browser is ignoring the <APPLET> tag.
HTML5 version not available | Scenario not running?
A new version of this scenario was uploaded on Wed Aug 10 00:35:48 UTC 2011 Unlocked the scenario.
A new version of this scenario was uploaded on Wed Aug 10 00:52:50 UTC 2011 Adjusted the screenshot.
A new version of this scenario was uploaded on Thu Aug 11 03:24:26 UTC 2011 Shrunk the size of the world.
A new version of this scenario was uploaded on Thu Aug 11 03:27:50 UTC 2011 Shrunk the size of the world even more.
A new version of this scenario was uploaded on Thu Aug 11 03:29:59 UTC 2011 Restored the size of the world to its default.
MatheMagicianMatheMagician

2012/5/29

Thanks, I used this in my image drawer program.
edparrishedparrish

2012/5/30

You are welcome!
A new version of this scenario was uploaded on 2017-11-25 05:44:25 UTC

Want to leave a comment? You must first log in.

Who likes this?

joandvgv davemib123 a_quiet_person MatheMagician Busch2207