Let's say that I have a file: 'mainGUI.java' and I want to, from a menu item,
open another GUI file: 'tutorialGUI.java'.

What would the code be to preform this?

Thanks everyone!

-WolfShield

Let's say that I have a file: 'mainGUI.java' and I want to, from a menu item,
open another GUI file: 'tutorialGUI.java'.

What would the code be to preform this?

Thanks everyone!

-WolfShield

Do you mean you want to open the file and view the code? Or do you want to run the "tutorialGUI.java" file?

If you want to open it you need to add a menubar to the GUI. Consult this website for steps on how to do this:

http://download.oracle.com/javase/tutorial/uiswing/components/filechooser.html

Cheers

Sorry,
I meant that if a user clicked on the menu item, another
window would come up with the tutorial in it.

So I would need to run the second file when the user clicked
the menu item.

-WolfShield

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.