Solved

Creating multiple frames in sequence in a for loop

Posted on 2004-08-30
6
194 Views
Last Modified: 2010-03-31
Hi again !!

I was trying to do something like this: I have a JDialog which shows up when a for loop is executing. In the for loop I manipulate the content of the JDialog to show some new content. This JDialog pops-up within the for loop. But when I run the program I see only the last content added to the content pane of JDialog. The reason being the for loop doesnt stop after showing the JDialog. I want the sequence to be maintained. So is there any way in which I can wait within the for loop for the JDialog window to close ?? So that when the user closes the JDialog I continue with the for loop and generate the next JDialog ??

regards
Ashish Sarin
0
Comment
Question by:sarin_ashish
  • 2
6 Comments
 
LVL 3

Expert Comment

by:CI-Ia0s
ID: 11936976
Create the dialog separately and have it updated from within the loop. Will that work or does the dialog have to be within the loop? (I'm not exactly sure whether you need to keep creating new dialogs or just updating one dialog...)
0
 

Author Comment

by:sarin_ashish
ID: 11937434
I figured out how this can be done. thanks.  I made a modal dialog, in which the method that creates the Dialog returns only after the shown dialog box is disposed.
0
 
LVL 3

Expert Comment

by:CI-Ia0s
ID: 11937450
Sounds good. :)
0
 
LVL 1

Accepted Solution

by:
Computer101 earned 0 total points
ID: 12319463
PAQed, with points refunded (50)

Computer101
E-E Admin
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
Are you developing a Java application and want to create Excel Spreadsheets? You have come to the right place, this article will describe how you can create Excel Spreadsheets from a Java Application. For the purposes of this article, I will be u…
Viewers will learn about arithmetic and Boolean expressions in Java and the logical operators used to create Boolean expressions. We will cover the symbols used for arithmetic expressions and define each logical operator and how to use them in Boole…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now