Java Reference
In-Depth Information
Error message
box displays
all nonsmoking
rooms are
occupied
OK button
FIGURE 5-42
7. Click the OK button.
The message box closes (Figure 5-43). The only available rooms are two
smoking rooms.
Close button
all nonsmoking
rooms are
occupied
two smoking
rooms are
unoccupied
FIGURE 5-43
OTHER WAYS
8. Click the Close button in the Reserve a Party Room window. If necessary,
click the Close button in the command prompt window.
The window closes and returns to TextPad because you coded an
addWindowListener() method. None of the data is saved for the next day
of reservations at the restaurant.
1. To compile, press
CTRL + 1
2. To compile at
command prompt,
type javac
Reservations.java
3. To run, press CTRL + 2 ,
enter data
4. To run at command
prompt, type java
Reservations , enter
data
 
Search WWH ::




Custom Search