Viewing the project code

PowerBASIC Forms provides four facilities for examining the generated source code for a project. These are divided into DDT Code, RC Code, New DDT Code, and New RC Code, and are available through the PowerBASIC Forms View menu.

DDT Code

This option displays the View DDT Code window, containing the generated BASIC code for the current project. This is the code that will be saved to disk with a File | Save or Save As operation. Code can also be copied from the View DDT Code window and pasted into the PowerBASIC IDE, to assist in the fine tuning of project code.

RC Code

As above, but for the resource file associated with the project. The resource file code can include version info tables, string tables, icons, bitmaps, etc.

New DDT Code

This option shows the code that PowerBASIC Forms will generate if the project is saved to disk with the File | Save As New option. In this case, manually added code is stripped from the source, just as if the project was being initially created (from scratch).

New RC Code

As above, but for the resource file associated with the project.

The view options provide valuable tools to assist in adding code to existing applications. For example, an existing project may be too significantly modified to reload successfully into PowerBASIC Forms, but an additional dialog may need to be added to the project. In this case, we can use PowerBASIC Forms to design just the new dialog, and we can then extract generated code from the View window(s), and then manually paste it into the existing project code.

 

See Also

Handling new vs. existing files

Saving a project

New PowerBASIC Forms projects

Named blocks

Parent and child dialogs

Opening existing project code

Migrating changes

Importing code