PreviousNext

Managing source files
Task
Steps

Create a source file.

> On the File menu, click New. In the wizard, follow the instructions on the screen.

Open a source file.

To open a file that is not part of a workspace project, on the File menu, click Open.

To open a file that is part of a workspace project, in the Workspace files view, expand the project file. Double-click a source file.

Change source files.

  1. On the Debug menu, click Stop Debugging.
  2. In the open source file, type new source code or delete existing code.

Add source files to a project.

  1. In the Workspace files window, click a project file.
  2. In the main window, on the Project menu, click Add File to Project.
  3. In the Add project to filename dialog box, select a file name with a .java file name extension.
  4. Click Open.

Create a template for new source files .

  1. On the Edit menu, click Preferences.
  2. Click the Editor tab.
  3. Click New Java file template.

Rename a source file.

  1. In the Files view, right-click the file name.
  2. Type a new file name.
  3. Click OK.

Note: If you have turned on source control integration, when you click OK, the BlackBerry® IDE prompts you to add the file to source control. To add the file to the default changelist, click yes. Remove the old file from the source control.

View source files while in debug mode

To view options while the application is in debug mode, pause the running of your application by setting breakpoints.

When the application reaches a breakpoint, the application pauses. In the Edit window, right-click the source file. On the shortcut menu, perform any of the following options.
Steps
Task

Click Break at Cursor.

Add or delete a breakpoint to your source code at the location of your cursor.

Click Show next Statement.

Show the next statement to run in your source code.

Click Watch.

Add a variable or expression to the watch pane at the location of your cursor.

Click Run to Cursor.

Run the current application up to the cursor location and start the debugging tool.

Click Set next statement.

Set the next statement to run in your source code.

Related topics


   BlackBerry