Building your first application with JBuilder
This tutorial produces a simple Hello World application. To make a printed copy of this tutorial, click the Print icon.
Step 1: Creating your project
The Project Wizard will create a project skeleton for you.
- Choose File|Close All to close any open projects or files.
- Choose File|New, and double-click the Application icon.
The Project Wizard appears.
- Edit the Title text field to read Hello World.
If you want, also enter your name, company name, and a description of your application in the appropriate fields.
- Click the Finish button.
The AppBrowser window appears, showing the HTML page "Project Notes" with the information that you entered for the Project Wizard.
Then the Application Wizard dialog appears.
Step 2: Generating your source files
The Application Wizard will create the .java files to go into the project skeleton created by the Project Wizard.
- Edit the Package text field to read Hello. (Note: This is a case-sensitive Java package name.)
- Edit the Class text field to read Hello. (Note: This is a case-sensitive Java class name.)
- Check the Generate Header Comments check box if you want the information you entered for the Project Wizard to appear at the start of the all source
files that the Application Wizard generates.
- Click the Next button.
The Application Wizard: Step 2 of 2 dialog box appears.
- Edit the frame's Class text field to read HelloFrame.
- Edit the Title text field (for Frame Style) to read "Hello World".
- Set any of the check boxes for additional features that you want your application to have.
The basic code to support these features will be generated for you by the Application Wizard.
- Click the Finish button.
You will see new .java classes added to your project after the Application Wizard is done generating source code.
Step 3: Compiling and running your application
Now, compile and run the application that you have built.
- Choose Run|Run (or Shift+F9) to compile and run your application.
- Choose Help|About. The About dialog box for your application appears.
- Click the OK button to close the dialog box.
- You can click on any of the buttons on the toolbar. Because you have no events hooked up to these buttons yet, nothing happens.
- Choose File|Exit to close your application.
- Choose File|Save All if you want to save the source files that you have created.
Next Steps
To learn more about using Borland JBuilder: