This week's book giveaways are in the Refactoring and Agile forums.
We're giving away four copies each of Re-engineering Legacy Software and Docker in Action and have the authors on-line!
See this thread and this one for details.
Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Multiple Outputs in a Dialog Box?

 
Dan Bolens
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
One last question and then this project is finished! I need to finally output all my information gathered from this pizza program I'm making into a Dialog Box, but I have two dilemmas. The output is based off of 4 possible "if" statements currently (that just outputs in the console), and I don't know how to grabinformation from two out of the four possible "if" statements and stick it into into one Dialog Box. I've seen things like

where you just fit everything into one big command, but that doesn't solve my "if" statement problem (unless I program in 4 different possible output boxes for each scenario). The Dialog box would need to show a certain output based on what the user has entered previously (for instance, if the user entered "c" for circle instead of "r" for rectangle, the dialog box needs to display "diameter" instead of "dimensions").

Any tips?
 
Paul Clapham
Sheriff
Pie
Posts: 20763
30
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


Was that the sort of thing you had in mind?
 
Dan Bolens
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Paul Clapham wrote:

Was that the sort of thing you had in mind?


Yes, it was. Would I be able to print out two things in OptionPane like that? For instance

if I have a bunch of output from a second if statement that I need to include?
 
Paul Clapham
Sheriff
Pie
Posts: 20763
30
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Of course.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic