Tips on installing JBuilder
...
Installing JBuilder
• • • • Jbuilder 3.5 is provided on your CD Open the MyComputer icon, and use right-click to explore Double click: JB35windows unzip the 4 files into some temporary folder (e.g. c:\temp). This requires PKUnzip or similar • For each in turn (foundation, docs, samples and opentools), find the install.exe file and double click. This installs everything into C:\JBuilder35 by default • The executable is in C:\JBuilder\bin\JBuilder.exe (or use your start menu to launch)
Running JB for the first time
• When running JB for the first time, you will be asked for a serial number and a key • shhhhhh........... • Serial number: xa32-?5n6h-5398g • Access key: zd4-?7a
Using JBuilder
• A group of files are collected together into a project. • Each project has its own .jpr file • For each project, make a folder and put the Java files you need in there, e.g.
– C:\fred\java\MyFirstProject
• • • • ...Instrument.java ...MyInput.java ...Saxophone.java ...InstrumentTest.java
etc
Making a new project
• Choose FileNew Project • Follow the wizard. • Replace ....\untitled\untitled.jpr with, e.g. ...\MyProject\MyProject.jpr • Do not mess with the rest of the path here • You have the option of preparing some documentation for your project here (optional)
Adding files to your project
• Use the 'AddFile' icon (+) to add all the java files you will work with • Under ProjectProject PropertiesPaths, add the Folder containing your code to the Source Path • Under ProjectProject PropertiesRun, choose the file containing your main method • Build or make your project • Run your project
Avoiding problems
• Keep all files and only files associated with one project in a single folder • Make sure that folder is listed as one of the sources in the project properties list • Make sure you have chosen which file contains the main method
Why bother?
• With practice, managing multiple files becomes much easier • Documentation is immediately available (right click on any identifier to browse its documentation) • Building graphical interfaces is greatly simplified • Finding out what classes are available is greatly simplified • Syntax highlighting! Helps debugging. • A debugging tool is also included
Error messages you may meet: 1
• Warning #908: check sourcepath. source X.Java cannot be found.....by appending X.java to each sourcepath entry • Solution: projectproject propertiespaths and add the folder containing your source code to the source path
Error messages you may meet: 2
• Code compiles, but when you run it, you get the message:
– Exception in thread 'main'
• Solution: projectproject propertiesrun set the Main class to the file with your main method in it