home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
cset21v3.zip
/
INF
/
DDE3TT1E.INF
(
.txt
)
< prev
next >
Wrap
OS/2 Help File
|
1993-08-30
|
190KB
|
1,004 lines
ΓòÉΓòÉΓòÉ 1. Special Notices ΓòÉΓòÉΓòÉ
References in this information to IBM products, programs, or services do not
imply that IBM intends to make these available in all countries in which IBM
operates.
Any reference to an IBM licensed program in this help is not intended to state
or imply that only IBM's licensed program may be used. Any functionally
equivalent product, program, or service that does not infringe any of IBM's
intellectual property rights may be used instead of the IBM product, program,
or service.
Evaluation and verification of operation in conjunction with other products,
except those expressly designated by IBM, is the user's responsibility.
IBM may have patents or pending patent applications covering subject matter in
this help. The furnishing of this help does not give you any license to these
patents.
The following terms used in this publication are trademarks or service marks of
IBM Corporation in the United States or other countries. They are denoted by an
asterisk (*) when they first appear in the text.
IBM
OS/2
C Set ++
Presentation Manager
Workplace Shell
WorkFrame/2.
ΓòÉΓòÉΓòÉ 2. Start Here ΓòÉΓòÉΓòÉ
About WorkFrame/2 Version 1.1
The IBM* WorkFrame/2* Version 1.1 integrated development environment provides a
project-oriented environment that you can customize to suit your needs. In
addition to its graphical interface, which makes tasks such as setting compiler
options quick and easy, WorkFrame/2 also provides useful tools such as a Make
File Creation Utility and Library Utility to enhance your productivity.
The WorkFrame/2 V1.1 product integrates the IBM C/C++ Tools compiler, debugger,
Developer's Toolkit tools, and any other tools you choose, to create a complete
development environment.
Please select the Forward push button to continue.
ΓòÉΓòÉΓòÉ 2.1. About This Tutorial ΓòÉΓòÉΓòÉ
This tutorial assumes you are using the IBM* C/C++ Tools compiler. If you are
not, you can still review the tutorial to learn how to set up projects and
invoke actions.
Using a simple program provided with the IBM C/C++ Tools product, you will
interact directly with the WorkFrame/2* V1.1 product to go through the
development process, from the creation of the program as a project to its
integration as a tool, and finally, its deletion.
This tutorial walks you through the following series of WorkFrame/2 V1.1 tasks
and takes one to two hours to complete:
o Setting up your environment
o Creating a project
o Editing a file
o Creating a Make file
o Making a project
o Running a project
o Adding a tool
o Deleting a project.
Note: Work through the lessons in the correct order without skipping any
lessons. Each lesson builds on the work you have done in the previous
lessons.
ΓòÉΓòÉΓòÉ 2.2. Using this Tutorial ΓòÉΓòÉΓòÉ
If you want to leave the tutorial and come back to it at a later time, use the
system menu to close the WorkFrame/2* V1.1 product, and when prompted to save
the profile, click on the Yes push button.
For convenience, you might prefer to print the tutorial rather than follow it
online. To print it, select the Print push button below.
Because the WorkFrame/2 interface offers a number of features that are ideal
for mouse users, this tutorial describes the steps as performed with a mouse.
If you prefer, you can also perform these steps using your keyboard. Shortcut
keys are indicated on pull-down menus, and underlined in windows.
The WorkFrame/2 product has online help. If you would like additional help for
an option, entry field, or push button, make that item active and press F1 or
the help button. For general help on the active window, press F2. You can also
access help from the Help pull-down.
ΓòÉΓòÉΓòÉ 2.3. About the Sample Program ΓòÉΓòÉΓòÉ
If you installed the IBM* C/C++ Tools product in the default C:\IBMCPP
directory, the sample program HELLO2.C that you will use for this tutorial is
in the C:\IBMCPP\WKFRAME directory.
Note: This tutorial assumes that you installed the IBM C/C++ Tools product in
the default C:\IBMCPP directory, and the WorkFrame/2 version 1.1 product
under C:\IBMWF. If you installed them in different directories,
substitute your own directory name wherever you see these paths.
ΓòÉΓòÉΓòÉ 3. Lesson 1: Customizing the Environment ΓòÉΓòÉΓòÉ
The WorkFrame/2* V1.1 product allows you to size and position the windows
within the WorkFrame/2 environment, change the color of the background, change
the color and font of text within the windows, and add tools to the tools list.
In this lesson, you will start WorkFrame/2 V1.1 and learn how to customize its
environment.
All customization that you perform while working with the WorkFrame/2 product
can be saved so that your settings are preserved for the next time you use the
product.
ΓòÉΓòÉΓòÉ 3.1. Starting WorkFrame/2 V1.1 ΓòÉΓòÉΓòÉ
You can start WorkFrame/2* V1.1 from an OS/2* command prompt, or from the
WorkFrame/2 V1.1 folder on the Desktop.
Starting WorkFrame/2 from a Command Line
1. At an OS/2 command prompt, change to the WorkFrame/2 directory, C:\IBMWF.
2. Start the WorkFrame/2 product by typing:
WFENV
This command file sets up any necessary environment variables and invokes
the WorkFrame/2 V1.1 product.
Starting WorkFrame/2 V1.1 from the Desktop
You can also start the WorkFrame/2 product directly from the Desktop folder.
1. From the Desktop, select the IBM WorkFrame/2 icon. The IBM WorkFrame/2 -
Contents window appears.
2. From this window select the WorkFrame/2 icon. The WorkFrame/2 logo appears.
3. Click on OK to close the logo window and proceed to the product windows.
The WorkFrame/2 product is opened and a menu bar and two windows appear.
ΓòÉΓòÉΓòÉ 3.2. Two Initial Windows ΓòÉΓòÉΓòÉ
When you start the WorkFrame/2* V1.1 product for the first time, the
WorkFrame/2 logo appears (if you did not disable the logo display from the
operating system). Click on OK to close the logo window and proceed to the
product windows. A menu bar and two windows appear.
The two windows that appear are the Action Log and the Project Control windows.
The Action Log window lists the tasks you have performed using the WorkFrame/2
product. Whenever you start or end a task, a line is written to the Action
Log, giving you an audit trail of activities performed in a particular session.
The Project Control window lists your existing projects. The project window
currently lists several projects that are provided with the C/C++ Tools and
WorkFrame/2 product. From this window, you can add new projects, or change and
delete existing projects. You can also select the project you want to work
with from the Project Control window.
ΓòÉΓòÉΓòÉ 3.3. Changing the WorkFrame/2 V1.1 Environment ΓòÉΓòÉΓòÉ
Try performing these customization tasks:
1. You can move and size windows within the WorkFrame/2* V1.1 environment just
as you do with any other window in the Workplace Shell*. Position and size
the windows as they suit you.
2. Try changing the background color for the main window:
a. From the Configure pull-down menu, select Background Color.
b. From the Configure Background Color window, click on a color of your
choice.
c. Click on OK to change the color of the background from the default color
to your selected color.
You can also use the Configure pull-down to specify the tools you want in your
tools list, the sessions you want included in the Switch List, and other
preferences. Lesson 7: Adding the Program to the Tools List will show you how
to add a tool to your tools list.
ΓòÉΓòÉΓòÉ 3.4. Saving the Changes ΓòÉΓòÉΓòÉ
To save the settings you made to the WorkFrame/2* V1.1 environment:
From the File pull-down, select Save Settings Both to save both your
window positions and your profile, which consists of your selection of
fonts, colors, tools, and other preferences.
ΓòÉΓòÉΓòÉ 3.5. Lesson 1: Summary ΓòÉΓòÉΓòÉ
You have learned how to:
o Start WorkFrame/2* V1.1
o Use the Action Log and Project Control windows
o Size and position WorkFrame/2 windows
o Change the background color
o Save the changes that you made so that every time you start up the
WorkFrame/2 V1.1, the screen appears as it does now.
ΓòÉΓòÉΓòÉ 4. Lesson 2: Creating Projects ΓòÉΓòÉΓòÉ
To begin developing a program using the WorkFrame/2* V1.1 product, you must
first create a project for it. In this lesson you will create the HELLO2
project, and associate the project with the IBM* C/C++ Tools language profile
and a number of compile and link options.
A WorkFrame/2 V1.1 project is a grouping of files that appear in a WorkFrame/2
window. A project can be either a base project or a composite project.
A base project consists of a language profile, a source file or files, a make
file, a target file, and some associated compile, link and make and debug
options.
A composite project is a collection of base projects or other composite
projects. Composite projects allow you to arrange projects hierarchically.
ΓòÉΓòÉΓòÉ 4.1. Creating the HELLO2 Project ΓòÉΓòÉΓòÉ
To create the HELLO2 project:
1. Click on the New push button in the Project Control window to open the New
Project window.
2. In the Project description field of the New Project window, type:
Hello2 Sample Project
The description you give in this field is used to identify the project in
headings, messages, and lists. Ensure that each project you create has a
unique description.
3. In the Project file name field, type:
HELLO2
This name is used to create the control file for the project. The control
file contains information about the project's language profile, associated
options, and other attributes. The extension .PRJ is appended to the name
you enter. The control file is stored in the WorkFrame/2 V1.1 home
directory, C:\IBMWF.
4. Under Project Type, the Base project radio button is already selected.
You do not need to change the setting.
The Hello2 Sample Project is considered a base project. A base project is used
to build a single executable module (EXE), dynamic-link library (DLL), or
similar object.
A composite project is a collection of sub-projects, that is, other base or
composite projects, that allow you to build more complex applications. For
more information on composite projects, see the IBM WorkFrame/2 Introduction
booklet and the WorkFrame/2* V1.1 online help.
ΓòÉΓòÉΓòÉ 4.2. Completing the Create a Project Window ΓòÉΓòÉΓòÉ
To complete the New Project window:
1. When you have completed the information in the New Project window, click
on the More push button. Another window appears where you can enter more
information about your project.
2. In the Directory field, type:
C:\IBMCPP\WKFRAME\HELLO2
This is the directory where the files are stored for the sample project.
For this tutorial, the directory already exists. If you type the name of a
directory that does not exist, the WorkFrame/2 product can create it for
you.
3. In the Target file name field, type:
HELLO2.EXE
The target file defines the object to be built by the project (usually an
executable module or DLL). Later you can perform the Run and Debug actions
on the project's .EXE file.
4. In the Make file name field, type:
HELLO2.MAK
Note that you may have to delete or type over the text that initially
appears in this field.
HELLO2.MAK is the name of the make file that is to be used to create the
target file. The HELLO2.MAK file does not exist yet, but is created later
in this tutorial.
5. Leave the File mask field as it appears.
When you later open the project window, only files with names that match
the file mask are displayed. For example, if the file mask was *.c , only
the files with the extension *.c would be displayed in the project window.
6. The Languages field is a combination box indicating the currently selected
language from a list of available language profiles.
Select the arrow on the field to display the list of available languages,
and select IBM C/C++ Tools from the list.
This associates things like the IBM* C/C++ Tools compiler, appropriate
linker, and make utility with this project.
ΓòÉΓòÉΓòÉ 4.3. Finishing Project Creation ΓòÉΓòÉΓòÉ
To complete the project creation:
1. On the Create window, click on the OK button to create the project. The
new project appears in the Project Control window and a line is written in
the Action Log indicating that the project was created.
2. Click on Cancel to close the New Project window.
If you had more projects to create you would have repeated the process for
each project before closing the New Project window. The example used in this
document is very simple. Your own project would typically consist of multiple
executable files. You would then define each executable as a base project and
then collect all the projects together into one or more composite projects.
For more information on creating composite projects, please refer to the
on-line help.
ΓòÉΓòÉΓòÉ 4.4. Setting Options for a Project ΓòÉΓòÉΓòÉ
You can set options for a project as you create it in the Create Project
window, or later from the Options pull-down menu after you have created and
opened the project. In the case of the IBM* C/C++ Tools compiler, however,
special information for the linker is stored in the project file by the
compiler. Because of this, the project file must exist before compiler options
are set. Thus, you must finish creating the object before setting options for
it.
Note: Setting options for a project is optional, as defaults are provided.
However, because neither the compiler nor the linker support debugging
information by default, you must specify these options if you want to
debug your program. We will do this in the following steps.
ΓòÉΓòÉΓòÉ 4.5. Opening a Project ΓòÉΓòÉΓòÉ
Before setting any options for a project, you must first open it.
To open the Hello2 Sample Project:
1. Select the Hello2 Sample Project project from the list of projects in the
Project Control window
2. Then, click on the Open push button. The Hello2 Sample Project window
appears.
You can also double-click on the project name to open it.
The Hello2 Sample Project window contains a list of all files that match the
file mask. The file mask *.* indicates that all files are displayed. Because
there is only one file in the sample project, only the HELLO2.C file appears.
ΓòÉΓòÉΓòÉ 4.6. Setting HELLO2 Compiler Options ΓòÉΓòÉΓòÉ
Now that the Hello2 Sample Project window is open, you can set the compiler
options for the HELLO2 project:
1. From the Options pull-down on the WorkFrame/2* V1.1 main window, select
Compile options. The IBM C/C++ Tools Compiler Options notebook appears.
Each page in the notebook corresponds to a category of processing options
that are defined in the IBM C/C++ Tools Programmer's Guide. To get help
on any option in the notebook, focus on the control and press F1.
2. Select the Debugging tab in the notebook.
3. Select the Generate debugging information check box.
4. Now select the Other tab in the notebook.
The options in this page allow you to control such things as whether the
char data type is signed or unsigned by default, and if the compiler
should invoke the linker automatically.
5. Select the Perform compile only, no link check box.
This field indicates that you want the linker invoked as a separate step
of the build process.
6. Select the OK push button in the note book to close the notebook and
confirm the changes you have made.
ΓòÉΓòÉΓòÉ 4.7. Setting HELLO2 Link Options ΓòÉΓòÉΓòÉ
Now set the linker options for the HELLO2 project:
1. While the HELLO2 project window is still open, select Link options from
the Options pull-down in the main WorkFrame/2* V1.1 window. The IBM* C/C++
Tools Linker Options notebook appears containing pages that represent
categories of linker options.
2. Click on the Generation tab on the notebook.
3. Select the Include debug information check box on the first Generation
page. to have the linker preserve the debug information.
4. Select the Window radio button from the Application Type group of radio
buttons near the bottom of the page, if it is not already selected.
Selecting Window for the Application Type instructs the linker to generate
a text-windowed application. By default, the linker attempts to build an
application that does not use Presentation Manager* (PM) services into a
text-windowed application. By explicitly selecting this option you
eliminate a warning message at link time.
5. Close the Linker Options note book by selecting the OK push button.
ΓòÉΓòÉΓòÉ 4.8. Lesson 2: Summary ΓòÉΓòÉΓòÉ
In this lesson, you have learned how to:
o Create a base project, telling WorkFrame/2* about your project, where its
files are, and what names you want to use for its parts
o Open a project, displaying its corresponding project window
o Associate the project with the IBM* C/C++ Tools compiler and debugger
o Specify some compile and link options that should be used when building the
program.
ΓòÉΓòÉΓòÉ 5. Lesson 3: Changing a Source File ΓòÉΓòÉΓòÉ
In this lesson, you will invoke the editor to edit the HELLO2 project source
file. While in the editor, you will add two syntax errors that will cause
compilation errors.
ΓòÉΓòÉΓòÉ 5.1. Editing the HELLO.C Source File ΓòÉΓòÉΓòÉ
To edit the HELLO2.C file:
1. Highlight the HELLO2.C file in the Hello2 Sample Project window and click
on the Process push button (you can also double-click on the file name to
edit it). The editor is started and an editing window appears with the
HELLO2.C file loaded.
The WorkFrame/2* installation program defines the Enhanced Editor (EPM) as
the default editor to use. You can specify that the WorkFrame/2 V1.1
environment use your own editor. For more information on integrating your
own editor, see the on-line help.
2. Remove the trailing semicolon from the first printf statement. This will
cause the first compilation error.
3. Change return 0; to return i;
Because i is not defined, a second compilation error will occur.
4. Select Save and quit from the File pull-down in the editor.
ΓòÉΓòÉΓòÉ 5.2. Lesson 3: Summary ΓòÉΓòÉΓòÉ
You have learned how to invoke the editor for a project file from the Project
Control window.
Note that highlighting a file name and clicking on Process (or double-clicking
on the name of the file) always invokes the editor unless the selected file is
an executable. Executable files are run instead of edited.
ΓòÉΓòÉΓòÉ 6. Lesson 4: Creating a Make File ΓòÉΓòÉΓòÉ
This lesson describes the steps necessary to create a make file for a project.
You will use the Make File Creation utility to create a make file that performs
a compile and a link.
Note: You could also provide your own make file instead of creating one using
the Make File Creation Utility.
The Make File Creation utility builds two files:
1. The first file is the make file itself. This is the file that was
specified when you created the HELLO2 project (HELLO2.MAK).
2. The second file is a dependencies file. The dependencies file indicates
the relationships between the project parts.
The Make File Creation utility assumes that you are working with the standard
NMAKE.EXE and LINK386.EXE programs. If you are using a different make utility
or linker, the output of this process could require modification, unless your
own make utility or linker accepts the same input as the corresponding
standard program.
ΓòÉΓòÉΓòÉ 6.1. Starting the Make File Creation Utility ΓòÉΓòÉΓòÉ
From the Tools pull-down menu of the main WorkFrame/2* V1.1 window, select
Make file creation. The Make File Creation window appears.
The top two list boxes contain the output of the Make File Creation process:
o The first list box contains the make file. The name of the make file is
determined by the name you specified in the Make file name field of the
Create Project window when you created the project.
o The second list box contains the project dependency information. The
dependency file name is created by WorkFrame/2 using the target file name as
a model. For this sample project, the dependency file name is HELLO2.DEP.
The remaining controls are used as input to the Make File Creation process.
You can change compile and link options for the open project here by selecting
the Compile Options or Link Options push button. For the purposes of this
tutorial, leave the compile and link options as you specified when you created
the project.
ΓòÉΓòÉΓòÉ 6.2. Selecting Make File Actions ΓòÉΓòÉΓòÉ
To create a make file, you will need to specify a set of actions to be
generated and a set of files to analyze:
1. Select Compile and Link from the Actions list box in the Make File
Creation window.
Note: The Make File Creation utility is also capable of generating
statements in support of the IPF compiler, the resource compiler,
and the message service utilities (MKMSGF and MSGBIND). See the
on-line help for more information.
2. Select HELLO2.C from the files list. This indicates that you want to
create the make and dependencies file based on the HELLO2.C file.
Your project could contain hundreds of source files. In this case, the
Make File Creation Utility analyzes the list of files and makes
assumptions about file types based on their extensions and the actions you
selected. The Make File Creation Utility produces a make file and a
dependency file for all the files selected.
If you did have hundreds of files to be included in the make file, you
could select them all at once by double-clicking with mouse button one on
the directory name that appears directly above the files list. The Make
File Creation Utility is able to distinguish between valid and invalid
files based on the actions you selected.
ΓòÉΓòÉΓòÉ 6.3. Starting the Make File Creation Process ΓòÉΓòÉΓòÉ
To start the make file creation process:
1. Click on the Start push button to begin the make file creation process.
You cannot perform further actions on the Make File Creation window while
the Make File Creation process is running, although you can continue to
perform tasks in other windows.
The Make File Creation process displays status information in a static
field immediately below the Actions list. Note that the status
information appears very quickly for the sample project.
When the actions are complete you will hear an audible alarm.
2. Click on OK to save the make and dependency files and close the Make File
Creation window.
3. In the Hello2 Sample Project window, click on the Refresh push button.
The .MAK and .DEP files appear in the file list with your HELLO2.C file.
ΓòÉΓòÉΓòÉ 6.4. Lesson 4: Summary ΓòÉΓòÉΓòÉ
You have learned how to:
o Create a make file to use with the sample project
o Instruct the Make File Creation utility to build a make file that takes the
source file and compiles it using the compile options associated with the
project
o Instruct the Make File Creation utility to generate a link step and generate
the target file that you specified when creating the project.
You were able to create the make and dependency files without knowing the name
of the compiler or the linker, the syntax of their invocation strings, or the
syntax of the make file.
ΓòÉΓòÉΓòÉ 7. Lesson 5: Making the Project ΓòÉΓòÉΓòÉ
This lesson describes how to invoke the NMAKE program, using the Make action
from the Actions pull-down on the main WorkFrame/2* V1.1 window. NMAKE is a
compiling and linking aid that searches for files changed since the last
compile and recompiles only the changed files. The NMAKE program is provided
with the OS/2* Developer's Toolkit.
You will perform the make action against the files you created in the previous
lessons.
When you perform the Make action on the sample project, compiler errors are
detected. These are the errors that you added in Lesson 3: Changing a Source
File. The errors are highlighted in the output window. You will fix the errors
by invoking the EPM editor directly from the NMAKE output window. The NMAKE
utility is invoked on the sample project again, and this time the process is
successful.
ΓòÉΓòÉΓòÉ 7.1. Invoking the Make Program ΓòÉΓòÉΓòÉ
To invoke the NMAKE program to perform a make action with the newly created
HELLO2.MAK make file:
Select Make from the Actions pull-down menu on the main WorkFrame/2* V1.1
window. A monitor window appears, where the output of the make process is
displayed.
When the process is complete you hear a low-pitched audible alarm indicating
that an error has occurred.
ΓòÉΓòÉΓòÉ 7.2. Correcting the Errors ΓòÉΓòÉΓòÉ
There are a number of compiler error messages in the output window:
1. The two lines which contain compilation errors appear in the monitor
window. Select the first error message and double click on it to invoke
the editor.
Note: If you are not using the EPM editor, skip to step 4 of the
following page, Getting Details on Errors and Functions
2. In the editor, the HELLO2.C file is displayed and the cursor is positioned
on the line with the first error. Select Describe error from the Compiler
in the EPM editor pull-down to display the error message text for that
error.
ΓòÉΓòÉΓòÉ 7.3. Getting Details on Errors and Functions ΓòÉΓòÉΓòÉ
Note that the Compiler pull-down in the EPM editor is only present when it is
invoked by double-clicking on errors in the monitor. You can use the Compiler
pull-down to move between the two errors, selecting the Next error or Previous
error menu options. This is particularly useful if there are a number of
errors in a program.
Now try performing these tasks on the compiler errors in the source-code:
1. Click on the Details push button to see help for the error message that is
highlighted in the Describe errors list.
2. Press the Esc key to close the help window, then click on the Cancel push
button on the Describe Error window to return to the editor session.
3. Next, put the cursor on the printf statement and press Ctrl-h. Help for
the printf function appears.
You can invoke help within EPM for any language construct or function this
way.
4. Close the help window then place the cursor on the first printf statement
in the source file and add a semicolon to the end.
5. Put the cursor on the return i; statement and change it to return 0;
6. Select Save and quit from the File pull-down of the EPM editor to save the
file and exit from the editor.
ΓòÉΓòÉΓòÉ 7.4. Performing a Successful Make ΓòÉΓòÉΓòÉ
Now that you have corrected the errors in the HELLO2.C file, you can try to
perform a successful make action:
1. Close the monitor window by clicking on the Cancel button.
2. Re-invoke the make process by clicking on Make from the Actions pull-down
menu. A new monitor window is started. When the process is complete, you
hear a high-pitched audible alarm indicating that the make command was
successful.
3. Click on the Cancel push button to close the monitor window.
4. Click on the Refresh push button in the Hello2 Sample Project window. The
target file HELLO2.EXE appears in the project window.
ΓòÉΓòÉΓòÉ 7.5. Lesson 5: Summary ΓòÉΓòÉΓòÉ
In this lesson, you:
o Invoked the Make utility
o Used the editor to correct compilation errors in the HELLO2 source-code
o Obtained help on error messages and library functions
o Re-invoked the Make process to successfully create the HELLO2.EXE target
file.
You could use the IBM* C/C++ Tools debugger to debug a project that has
errors. For detailed information on how to use the C/C++ Tools debugger see
the IBM C/C++ Tools Debugger Introduction booklet or refer to its online help
and tutorial.
ΓòÉΓòÉΓòÉ 8. Lesson 6: Running the Project ΓòÉΓòÉΓòÉ
This lesson shows you how to run the sample project. In order to run a project,
a project window must be open. Select Opening a Project to review the steps on
how to open a project.
To run the Hello2 Sample Project:
1. Select Run from the Actions pull-down menu in the WorkFrame/2* V1.1 main
window.
The WorkFrame/2 window becomes an icon, and a new window in which the
program runs, is opened
2. Press Enter to end the program and close the window.
ΓòÉΓòÉΓòÉ 9. Lesson 7: Adding the Program to the Tools List ΓòÉΓòÉΓòÉ
In this lesson you will add the HELLO2.EXE program to your tools list.
Programs that appear on the tools list can be used as tools for other projects.
This lesson describes two ways of adding a tool to the tools list. You can add
a tool by filling in the information in a New Tool window, (described in
Completing the New Tool Window), or you can add a tool by transferring
information from the project to the tools list (described in Adding a Tool by
Dragging a Project.)
ΓòÉΓòÉΓòÉ 9.1. Accessing the New Tool Window ΓòÉΓòÉΓòÉ
To access the Change Tools list:
1. Close the Hello2 Sample Project window by clicking on the Cancel push
button.
2. Under the Configure pull-down menu from the action bar on the main
WorkFrame/2* V1.1 window, click on Tools. The Configure Tools window
appears.
3. Click on the New push button to open the New Tool window.
ΓòÉΓòÉΓòÉ 9.2. Completing the New Tool Window ΓòÉΓòÉΓòÉ
To complete the New Tool window:
1. In the Program title field, type:
HELLO2
This name appears as the title for the tool in windows, pull-downs, list
boxes, and messages.
2. In the Path and file name field, type:
C:\IBMCPP\WKFRAME\HELLO2\HELLO2.EXE
3. In the Startup directory field type:
. (a period)
The period indicates that WorkFrame/2* should use the project directory as
the current directory when the tool is started.
4. Leave the Invocation string field blank.
This field is required only if your application requires parameters on
startup. The HELLO2 program does not require parameters on startup. You
can specify an invocation string here, or you can indicate that you want
to be prompted for the invocation string when the program starts.
If you want to be prompted, enter the text of the prompt in the Prompt
string field and turn on the Prompt required check box.
5. Select Program determines as the Program type.
6. In the Execution mode field, the Foreground radio button is pre-selected.
Accept the default Execution mode to indicate that you want the tool to
run in the foreground.
The WorkFrame/2 product issues a call to DosStartSession to start the
program. If you choose to run the tool in the background, the tool must
not require user interaction. When it is run, it is invoked in a monitor
window similar to the windows used when you invoked the Make process.
7. Click on the OK push button to add HELLO2 to the Tools list and close the
New Tool window. The Configure Tools window reappears.
8. Click on OK to close the Configure Tools list and accept the changes.
ΓòÉΓòÉΓòÉ 9.3. Adding a Tool by Dragging a Project ΓòÉΓòÉΓòÉ
If the tool you are adding is a WorkFrame/2* V1.1 project, you can use the
WorkFrame/2 V1.1 drag and drop feature to add the tool to the Tools List. The
fields in the New Tool window are initialized based on the project selected
from the Project Control window.
In this step, you will add the Hello2 Sample Project to the tools list again,
this time using the drag-drop method:
1. From the Configure pull-down menu from the the main WorkFrame/2 V1.1
window, click on Tools. The Configure Tools window appears.
2. Click on New to open the New Tool window.
3. In the Project Control window, highlight Hello2 Sample Project.
4. Holding down mouse button two, drag the project to the New Tool window.
5. Release mouse button two once the pointer is positioned over any input
field in the New Tool window. The fields in the window are initialized
with the characteristics of the Hello2 Sample Project.
6. For Program type, select the Program determines radio button.
7. In the Execution mode field, the Foreground radio button is pre-selected.
Accept the default Execution mode.
8. Click on OK to add HELLO2 to the Tools list and close the New Tool window.
The Configure Tools window reappears.
9. Click on OK to close the Configure Tools list and accept the changes.
ΓòÉΓòÉΓòÉ 9.4. Running the Tool ΓòÉΓòÉΓòÉ
Now try running the HELLO2 program from the Tools list:
1. Click on the Tools pull-down to verify that HELLO2 is now listed twice at
the bottom of the menu.
2. Run HELLO2 by selecting it from the Tools pull-down menu.
ΓòÉΓòÉΓòÉ 9.5. Lesson 7: Summary ΓòÉΓòÉΓòÉ
In this lesson you learned how to:
o Add a program to the Tools list by completing the New Tool window yourself,
or by using the drag and drop feature
o Run a program from the Tools list.
Note: Although the tool has been added to your tools list, it is only valid
for the current session. To save the tool so that it can be used in
other sessions, you must save your user profile by selecting
Save Settings Profile from the the File pull-down on the WorkFrame/2*
V1.1 main window.
ΓòÉΓòÉΓòÉ 10. Lesson 8: Deleting the Project ΓòÉΓòÉΓòÉ
In this lesson you will delete the Hello2 Sample Project from the WorkFrame/2*
environment.
The Hello2 Sample Project window must be closed (you already closed it in the
last lesson). If the project window is open, close it by clicking on Cancel.
ΓòÉΓòÉΓòÉ 10.1. Deleting the HELLO2 Project ΓòÉΓòÉΓòÉ
To delete the Hello2 Sample Project:
1. From the File pull-down menu on the main WorkFrame/2* V1.1, select
Deletion window to open the Delete window.
2. In the Project Control window, select the Hello2 Sample Project entry.
You may have to move other windows so they do not hide the Delete window.
3. Holding down mouse button two, drag the project to the Delete window then
release the mouse button.
A Confirm Deletion window appears.
4. Confirm the deletion by clicking on OK. Animation begins in the Delete
window.
The Hello2 Sample Project is now deleted from the WorkFrame/2 V1.1
environment. However, the HELLO2 directory and all of its files still
exist. You can delete them later from the command prompt if you want.
Note: You can also delete projects by highlighting them in the Project
Control window and clicking on the Delete push button.
ΓòÉΓòÉΓòÉ 10.2. Disabling Animation and Sound ΓòÉΓòÉΓòÉ
If you want to disable the animation and sound:
1. Select Preferences from the Configure pull-down on the WorkFrame/2* V1.1
main window.
2. Deselect the Animation check box to disable animation; deselect the Sound
check box to disable sound.
3. Click on the OK push button to accept the changes and close the
Preferences window.
ΓòÉΓòÉΓòÉ 10.3. Lesson 8: Summary ΓòÉΓòÉΓòÉ
In this lesson you learned how to:
o Delete a project from the Project Control window
o Disable animation and sound
ΓòÉΓòÉΓòÉ 11. Lesson 9: Closing the WorkFrame/2 Environment ΓòÉΓòÉΓòÉ
In this lesson, you will end your WorkFrame/2* V1.1 session.
ΓòÉΓòÉΓòÉ 11.1. Ending the WorkFrame/2 Session ΓòÉΓòÉΓòÉ
To end your WorkFrame/2* V1.1 session:
1. Select on Close from the system menu.
A confirmation window appears asking if you want to save the WorkFrame/2
profile before ending the session.
2. Click on No in the confirmation window. This indicates that you do not
want to save the information and files that were created using this
tutorial. If you do want to save the files click on Yes.
ΓòÉΓòÉΓòÉ 11.2. Lesson 9: Summary ΓòÉΓòÉΓòÉ
In this lesson you learned how to end your WorkFrame/2* V1.1 session without
saving the changes that you made.
ΓòÉΓòÉΓòÉ 12. Tutorial Summary ΓòÉΓòÉΓòÉ
This tutorial has guided you through all the major steps of the development
process. You should now be able to effectively use the WorkFrame/2* V1.1
environment. The WorkFrame/2 product itself offers some other tools and
features that could be of interest to you. Use the online help and
documentation to familiarize yourself with the other features of this product,
and increase your productivity.
ΓòÉΓòÉΓòÉ <hidden> ΓòÉΓòÉΓòÉ
Trademark of the IBM Corporation
ΓòÉΓòÉΓòÉ <hidden> ΓòÉΓòÉΓòÉ
Each WorkFrame/2 V1.1 project has an associated language profile
A language profile defines a number of things, including:
1. The executable files for the compiler, linker, debugger, and make utility
to be used for the project
2. The DLLs that let you specify options for the above programs
3. The default invocation string (if applicable) for the make utility and
debugger
4. Search paths for include files and libraries.
ΓòÉΓòÉΓòÉ <hidden> ΓòÉΓòÉΓòÉ
A linker is a program that resolves cross-references between separately
compiled object modules, and then assigns final addresses to create a single
executable program.