Top
PowerCOBOL V11.0 User's Guide
FUJITSU Software

2.1.2 The Project Manager Edit Menu

The Edit menu appears only if you have a project currently open

The Edit menu appears only if you have a project currently open and gives you access to functions in the PowerCOBOL Project Manager that may assist you in shaping the design of your application. Accessibility to functions in the Edit menu varies depending on what type of application component you have currently selected in the left windowpane. Note that the Edit menu only appears when you have a project loaded in PowerCOBOL.

The Edit menu appears as follows:

Figure 2.5 The PowerCOBOL Project Manager Edit menu

The Edit menu contains the following functions:

Expand All

Expands the project hierarchy to show all levels of the tree.

Cut

Removes the selected application component and stores it on the clipboard. At the next Cut or Copy command, the selection is erased from the clipboard.

Copy

Copies the selected application component to the clipboard without removing the selection from the current project definition.

Paste

Places the clipboard contents into the current project under the appropriate managing component in the hierarchical project tree. For example, if you have copied a form (window) and wish to insert it into the current project to create a separate identical form, you would insert this new form directly under the application module that will control the form. Note: The Paste command usually follows the Copy or Cut command.

Delete

Removes the selected application component from the current project definition.

Rename

Renames the selected application component in the current project definition.

Properties

Displays the Properties dialog box for the currently selected application component. This dialog box allows you to examine and modify properties similar to the Properties list in the right windowpane. The Properties dialog box differs from the Properties list in that it organizes related properties, whereas the Properties list presents all properties in alphabetical order. The Properties dialog box appears as follows:

Figure 2.6 The Form Properties dialog box

2.1.2.1 Object Options in the Edit Menu

A number of sub options are available from the Object selection on the Edit pull down menu. You may also right click on any object in the Project Manager Hierarchy and a context menu will appear containing options. The options found in the Edit->Object menu change dynamically depending upon the type of application object currently selected (highlighted) in the Project Manager hierarchy as noted below:

2.1.2.2 Object Menu Options (For a Project)

Figure 2.5 above shows the Edit->Object menu expanded for a Project (e.g. when the actual project name is currently selected in the Project Manager hierarchy). The options available include:

Create Module

Allows you to add a new executable module definition in your project. PowerCOBOL projects can create one or more executable modules.

Build All

Builds the project, compiling and linking only components that were changed.

Rebuild All

Rebuilds (compiles and links) all application components, regardless as to whether they were modified.

Utilities

Brings up the Find and Replace utility context menu. These utilities allow you to search through an entire project looking for search strings you may specify, and to optionally replace the search string with a new string.

Expand All

Expands the entire project hierarchy.

Properties

Brings up the Properties dialog box for the item currently selected in the project hierarchy.

2.1.2.3 Object Menu Options (For an executable Module)

When you select (highlight) an executable Module in the Project Manager hierarchy and select the Edit->Object menu, the following options are available to you:

Create Form

Creates a new form in the module.

Insert File

Allows you to insert an external file into the current PowerCOBOL project. External files supported are COBOL programs, Object files (.OBJ), Library files (.LIB), Bitmap files (.BMP), Icon files (.ICO), Cursor Files (.CUR), Image Lists (.BMP), Animate Cursor files (.ANI). If your executable module required the static linking of an external .OBJ or .LIB file that had been created outside of PowerCOBOL, for example, this is the option you would use to add it into your project.

Build

Invokes the Build facility.

Rebuild

Invokes the Rebuild facility.

Debug

Invokes the PowerCOBOL Debugger on the currently select module

Execute

Executes the currently selected module.

Register

Registers the currently selected module in the Windows Registry (invokes the Windows Regsvr32.exe utility).

Unregister

Unregisters the currently selected module from the Windows Registry (invokes the Windows Regsvr32.exe utility).

Utilities

Brings up the utilities context menu containing the Find and Replace utilities.

Expand All

Expands the Project Manager Hierarchy completely under the currently selected module.

Cut, Copy, Paste Delete

Standard Windows cut, copy paste and delete operations.

Rename

Allows you to rename the currently selected module.

Properties

Brings up the module's Properties dialog box.

2.1.2.4 Object Menu Options (For a Form)

When you select (highlight) a Form in the Project Manager hierarchy and select the Edit->Object menu, the following options are available to you:

Open

Opens the currently selected Form in the PowerCOBOL Form Editor, allowing you to modify it.

Compile

Compiles the currently selected Form. Note that "under the covers", PowerCOBOL creates a separate program for each Form defined in a module. A PowerCOBOL executable Module is made up of one or more Forms compiled and linked together.

Edit ENVIRONMENT DIVISION

Allows you to modify the SPECIAL-NAMES, REPOSITORY, and FILE-CONTROL sections of the ENVIRONMENT DIVISION of the currently selected form. The FILE-CONTROL section is where you would place SELECT....ASSIGN TO statements to define an external data file to be accessed from a Form, for example.

Edit DATA DIVISION

Allows you to modify the BASED-STORAGE, FILE, WORKING-STORAGE, and CONSTANT sections of a Form. The FILE section, for example, is where you would place FD statements and associated record definitions for external data file definitions to be accessed from the Form The WORKING-STORAGE section is where you would define COBOL data items for the Form. Note that if you want to share these data definitions (both FD's and WORKING-STORAGE section items with event procedures in your Form, you must specify the IS GLOBAL optional phrase on each such definition. To share these definitions across separate executable modules, you must specify the optional IS EXTERNAL phrase on each such definition.

Edit PROCEDURE DIVISION

Allows you to create COBOL programs (scriptlets) that are not tied to any particular event and may be called from other event procedures or scriptlets. If you wanted to create a program to format dates for example and wanted to call it from several different places in your PowerCOBOL application, this is where you would define it. You create a new scriptlet by selecting the New option that appears. The PROCEDURE option allows you to specify declaratives and SQL cursor definitions so that they get executed firth when the form is initialized.

Edit Event Procedures

Shows a list of all of the event procedures that are available for the Form, and allows you to edit them. Event procedures are individual COBOL programs (also called "scriptlets") that you write to handle specific events, such as when a user clicks the mouse on a specific command button. The list presented her, however, are event procedures associated with the form itself - not the controls that you may have placed on the form. For example, you might want to use the "Opened" to write initialization code, as it gets triggered when the form is opened. If you see an asterisk character to the left of one of the event procedures in the context menu that appears, it designates that an event procedure currently exists for that event.

Preview

Previews the currently selected Form. This brings the form up on the desktop as it will look at execution time.

Tab Order

Allows you to define the tab order of controls on the form.

Insert Custom Property

Allows you to create a custom property for the form and to define its data type.

Insert Custom Method

Allows you to create a custom method and define its parameter usage.

Insert Custom Event

Allows you to create a custom event.

Menu Editor

Allows you to create or modify a menu for the form.

Print

Allows you to print information regarding the form.

Utilities

Brings up a child menu from which you can access the Find and Replace utilities.

Expand All

Expands the entire project hierarchy.

Cut

Standard Windows Cut function.

Copy

Standard Windows Copy function.

Paste

Standard Windows Paste function.

Delete

Standard Windows Delete function.

Rename

Allows you to rename the form.

Properties

Brings up the form's Properties dialog box.

2.1.2.5 Object Menu Options (For Script)

When you select (highlight) the Script(COBOL Script) entry in the Project Manager hierarchy and select the Edit->Object menu, the following options are available to you:

Print Procedures

Allows you to print the source code of existing event procedures.

Utilities

Brings up the utilities context menu allowing access to the Find and Replace utilities.

Compile

Compiles the event procedures.

Edit ENVIRONMENT DIVISION

Allows access to the form's ENVIRONMENT DIVISION sections.

Edit DATA DIVISION

Allows access to the form's DATA DIVISION sections.

Edit PROCEDURE DIVISION

Allows access to the form's PROCEDURE DIVISION.

Properties

Brings up the Properties dialog box for the currently selected item in the project hierarchy.