Specifying the Main Class to Run for a Project
To run a program from within the IDE, you must specify the
main the Java class file, or starting point, of your project. If you create
a project from a template, you are prompted to specify the main
class the first time you compile the program. You can also set
the main class using the Project menu in the main window.
To specify the main class for the current project:
- From the main window, choose Project
Set Main Class (Ctrl-Shift-M).
- In the Select Main Class dialog box, select the class that contains
the main method.
- Click OK.
Legal Notices