New to java how does one JFrame window link to another JFrame window for example lets say I have my main JFrame application window open and I click on another JFrame in the menubar. can someone give me example please
A JFrame is the outer-most UI Component for a Swing application. It acts as the parent container for all other components in your application. I usually expect to have only one of these per application.
I'm a bit confused by what you mean when you ask 'how does one JFrame link to another...'. What do you mean by 'link'. It has a few connotations so can you be more precise?
Tim
--------------------------- "Your morbid fear of losing,
destroys the lives you're using." - Ozzy
I have my main JFrame application window open and I click on another Jdialog, JInterFrame, (window?) in the menubar
I think this is better.
Because the JFrame hold the menubar and it is normal for keeping JFrame as the main program to control the flow.
Do you want the JFrame of one application to call another JFrame of another application
JDialogs aren't normal JFrames, they block the calling process untill they get a responce, and then they return an answer. Other JFrames will not block, and that makes communication between multipule JFrames difficult, but not impossible. All Swing commpoents use Listeners to communicate using a system of callbacks. RTFM about JFrames and Listeners...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.