Using the command-line tools
JBuilder includes the following command-line tools:
Installing JBuilder also installs the JDK command-line tools, such as:
- AppletViewer
- javadoc - comments extraction utility
Setting environment variables for command-line tools
The environment paths for the command-line environment are defined separately from the environment paths for the IDE. The SOURCEPATH and CLASSPATH environment variables must be set so the command-line tools can find the classes required for your program. The standard JBuilder setting for the class path includes several directories and zip files in the jbuilder\ directory. You might need to run jbuilder\bin\setvars.bat
to set the environment variables for the command line.
To set your environment variables:
- At the DOS prompt, enter
setvars c:\jbuilder
(assuming JBuilder is on drive C).
You can use the set
command to compare your environment variables before and after running setvars.bat.
You should not issue the setvars.bat
command more than once in a DOS session, because every time the command is issued, additional environment space is used up.
Setting the DOS environment space
When you issue the setvars.bat
command at the DOS prompt, you might get an Out Of Environment Space error, because only a small amount of environment space is allocated by default.
To increase the DOS environment space:
- In the DOS window, click the control menu in the upper left, and choose Properties.
- Click the Memory tab to show the Memory options page.
- In the Initial Environment drop-down list, select a reasonably large value, such as 2048. The other settings in the page can be left at Auto.
- Click OK to close the Properties dialog, and type
exit
at the prompt, to quit the DOS session.
- Start a new DOS session.
You should now be able to issue the setvars.bat
command successfully.
Running applets from the command line
To run an applet from the command line, you need to set the CODEBASE parameter and the environment variables, so that the HTML file can find the class files.
To run an applet from the command line:
- In the APPLET tag in the HTML file, specify CODEBASE="\jbuilder\myclasses".
- If necessary, run setvars.bat to set your paths (see above).