Managing Files in JBuilder

Home Up Search Java 2 API C++ Resources

In a JBuilder project, there are two kinds of files that can be opened:

  1. Files that are in the project:   These are the files that are compiled when the project is "made" or "rebuilt".   Be sure that all files you that are part of your Java program are part of the project.
  2. Files that are not in the project:   These files can be compiled manually, but are not part of the project management. 

It is important to understand the difference between the two types of files!

To create a new file in the project

  1. Select "File/New"  from the main menu. 
  2. Select what type of file you want.   The most common are "Class", "Application" or "Applet".
  3. Save the file with the desired name in the project directory or other desired directory.

To insert a file into the project:

  1. In the Project pane, click the folder icon with the green "+" sign on it.
  2. Browse for the file you want.   Multiple files may be selected by Ctrl -clicking the files.
  3. Be sure the "Add to Project" checkbox is checked.
  4. Click on "Open".
  5. Be sure that the package statements of any files added are consistent with the  default package directory for the project.   That is, the files added must be located in subdirectories directly below the default package directory.

To remove a file from the project:

  1. In the Project pane, click the folder icon with the green "-" sign on it.
  2. The file should disappear from the project list.