CA-Clipper For DOS Version 5.3. Getting Started Guide
CA-Clipper For DOS Version 5.3. Getting Started Guide
For DOS
Version 5.3
June 1995
(iOMPUTER 0
J4ssoc1ATES
Sottware superior by design.
~ PRINTEOON
\!ti RECYCLED PAPEA
© Copyright 1995 Computer Associates International, Ine.
One Computer Assoeiates Plaza, Islandia, NY 11788. All rights reserved.
Use of the software programs deseribed herein and this doeumentation is subjeet to the Computer
Associates License Agreement enclosed in the software package.
All product names referenced herein are trademarks of their respective companies.
Contents
Chapter 1 : Introduction
Welcome to CA-Clipper! ...................................................... 1-1
What's New in CA-Clipper? ................................................... 1-2
Version 5.3 Features ....................................................... 1-2
In This Guide ................................................................. 1-6
Installation ............................................................... 1-6
The Benefits of Using CA-Clipper .......................................... 1-6
Learning the Basics ........................................................ 1-7
Debugging a Simple Program .............................................. 1-7
Creating Data Structures ................................................... 1-7
DOS Online Documentation: The Guide To CA-Clipper ....................... 1-7
Where to Go from Here .................................................... 1-8
Chapter 2: lnstallation
In This Chapter ............................................................... 2-1
System Requirements ......................................................... 2-2
Installation Procedures ........................................................ 2-3
Installing CA-Clipper from Windows ....................................... 2-3
The Windows CA-Installer ............................................. 2-4
Full Installation ....................................................... 2-5
Partial Installation ..................................................... 2-5
Installing CA-Clipper from DOS ............................................ 2-8
The DOS CA-Installer ..................................................... 2-8
Full Installation or Partial Installation ................................... 2-9
The CA-Clipper Development Environment .................................... 2-11
The Directory Structure ................................................... 2-11
Environment Variables ................................................... 2-13
iv CA-Clipper
The Workbench Tools ........................................................ 3-31
The Browsers ............................................................ 3-33
Application Browser .................................................. 3-34
Module Browser ..................................................... 3-35
Entity Browser ....................................................... 3-36
Error Browser ........................................................ 3-39
The Editors .............................................................. 3-40
Source Code Editor ................................................... 3-41
Data Server Editors ................................................... 3-42
Form Editor ......................................................... 3-43
Menu Editor ......................................................... 3-49
The Debugger ........................................................... 3-51
Summary ................................................................... 3-52
Getting Storted v
LESSON 4: Using the Form Editor ............................................ 4-29
Creating a Form ......................................................... 4-29
Specifying Form Properties ............................................... 4-31
Using Auto Layout to Place Controls ...................................... 4-32
Specifying Control Properties ............................................. 4-34
Changing Control Types ................................................. 4-35
Creating a List Box ................................................... 4-35
Customizing a List Box ............................................... 4-37
Creating a Radio Button Group ....................................... 4-40
Customizing a Radio Button Group .................................... 4-41
Adding Push Buttons to a Form ........................................... 4-43
Specifying Control Order ................................................. 4-46
LESSON 5: lmporting an External File ......................................... 4-49
Importing DC_UTILS.PRG ............................................... 4-49
Using an Entity Browser to View DC_UTILS ............................... 4-51
LESSON 6: Using the Source Code Editor ...................................... 4-53
Modifying the DC_MENUTest() Function .................................. 4-54
Modifying the DiskDispTest() Function .................................... 4-56
Modifying the DiskDispAppend() Function ................................ 4-57
LESSON 7: Compiler and Linker Options ...................................... 4-60
Setting Compiler Options at the Application Level .......................... 4-60
Setting Linker Options at the Application Level ............................ 4-62
LESSON 8: Building and Executing DISKCA T ................................. 4-64
Building an Application .................................................. 4-64
Executing an Application ................................................. 4-65
Summary ................................................................... 4-67
vi CA-Clipper
Chapter 5 : Debugging a Simple Program
In This Chapter ............................................................... 5-1
Requirements for This Chapter ................................................. 5-2
Creating a Program with Errors ................................................ 5-3
Preparing Your Program for Execution .......................................... 5-4
Executing Your Program Using the Debugger ................................... 5-5
Isolating the First Error .................................................... 5-7
Correcting the First Error .................................................. 5-8
Starting the Next Debugger Session ............................................. 5-9
Isolating the Next Error .................................................... 5-9
Setting W atchpoints ...................................................... 5-11
Using Single Step Mode .................................................. 5-12
lmplementing a Temporary Fix ............................................ 5-13
Continuing Program Execution ............................................ 5-13
Viewing Your Program Results ............................................ 5-14
Correcting the Final Error ................................................. 5-14
Running the Final Test ....................................................... 5-15
Surnrnary ................................................................... 5-16
viii CA-Clipper
Chapter 1
lntroduction
Welcome to CA-Clipperl
Welcome to CA-Clipper 5.3, the development system far
database applications. This isa vastly enhanced release of the
popular CA-Clipper compiler, offering new opportunities and
technology to programmers of all levels and backgrounds.
This guide is designed to give you all the infarmation you need
far the installation of CA-Clipper, as well as to introduce you to
some of its new features.
1-2 CA-Clipper
What's New in CA-Clipper?
1-4 CA-Clipper
What's New in CA-Clipper?
• TBrowse Enhancements
New TBrowse instance variables include the following:
border, mRowPos, and mColPos. Also, the colorSpec
variable has been modified. Finally, four new methods have
been added: hitTest(), setKey(), applyKey(), and setStyle().
• Upgrade of Microsoft C
CA-Clipper has been upgraded to compile under Microsoft
C 8.0 (Microsoft Visual C/C++ 1.0). This upgrade entails a
switch from alternate to emulator floating point support,
enabling CA-Clipper to utilize a math coprocessor, if
present.
Nate that these changes require you to do the following:
Any routines written in C need to be recompiled with
the Microsoft C 8.x (Microsoft Visual C/C++ 1.x)
compiler
Replace the /FPa C compiler command line argument
with /FPi
Any references to LLIBCA.LIB in your make/link scripts
need tube changed lo LLII3CE.LIB
• New Replaceable Database Drivers (ROD)
Unless otherwise specified, the enhanced DBFNTX driver is
automatically linked into your application when you use the
CA-Clipper linker. Other RDDs, such as DBFCDX, have also
been enhanced.
CA-Clipper also provides two new RDDs, DBFMEMO and
DBFBLOB, for compatibility with FoxPro 2.
ln This Guide
This guide, Getting Started, is designed to take you the first few
steps into CA-Clipper. It contains installation instructions,
describes the CA-Clipper development environment and its
basic set of programming tools and documentation, and walks
you through several tutorials in order to familiarize you with the
Workbench and CA-Clipper utilities.
lnstallation
Chapter 2 gives complete instructions on how to install the
CA-Clipper development system on your computer. CA-Clipper
is much more environment intensive than its predecessors and,
therefore, is supplied with an installation program. In addition,
the compiler and linker take advantage of directory structures
for organizing files by project and type. This chapter describes
the CA-Clipper development environment and how the install
program works. It then instructs you how to begin the
installation process.
1-6 CA-Clipper
ln This Guide
1-8 CA-Clipper
Chapter 2
lnstallation
ln This Chapter
This chapter discusses requirements and procedures for
installing and starting CA-Clipper. Whether you're a new or
experienced CA-Clipper user, the installation procedure isa
required step for copying and organizing the necessary files on
your hard disk. The files on the distribution disks are
compressed into self-extracting archive files that cannot be used
and/ or executed otherwise.
Getting Started 2- l
System Requirements
System Requirements
The minimum and recommended system requirements needed
to install and run CA-Clipper are as follows:
2-2 CA-Clipper
lnstallation Procedures
lnstallation Procedures
If your system meets the requirements, you are ready to begin
the installation procedure. Note that CA-Clipper 5.3 may be
installed either from within MS-Windows or from DOS.
WARNING!
Click on 11 component to
11ltern11tely select and deselect it.
Component Description:
CA-Clipper Workbench Program Files
2-4 CA-Clipper
lnstallation Procedures
From here, you have two options. You can either install all of the
components that are part of the CA-Clipper package (i.e., the full
installation) or select only those components you know you are
going to need (i.e., a partial installation).
Full lnstallation
Partial lnstallation
Minimum lnstallation The minimum installation for CA-Clipper must include the
following options: CA-Clipper; Obj, Lib, Include; and System
Files. This will install all the system-defined libraries as well as
other components that are common to all DOS applications.
For the CA-Clipper Workbench, the first two options are basic
requirements-Workbench and Repository. The rest are
arbitrary.
Workbench This option installs ali of the necessary files for the Workbench,
the CA-Clipper interactive development environment. If you
plan to use the interactive development environment, you must
select this option.
Windows Help This option installs the Windows-style online help system
associated with the CA-Clipper Workbench. If you plan to use
context-sensitive help, you must choose this option.
Workbench Samp. This option installs the sample files that are used in the various
hands-on lessons in the printed documentation for the
CA-Clipper Workbench. Choose this option if you plan to follow
through the Workbench documentation examples.
CA-Clipper The CA-Clipper option installs the CA-Clipper compiler and all
necessary files for building applications. This option must be
installed in order to create any CA-Clipper application.
Obj, Lib, lnclude Files This option installs other files used by CA-Clipper including
library and header files.
DBU Utility This option installs the CA-Clipper database utility, DBU.EXE,
which allows you to build database files, add data to the files,
browse existing da ta, create and attach index files, and construct
views using a completely menu-driven system.
2-6 CA-Clipper
lnstallation Procedures
RL Utility This option installs the CA-Clipper report and label utility,
RL.EXE, which gives you the ability to create and modify
standard dBASE III PLUS report and label definitions and use
them in your applications.
Utility Sources This option installs the source code used by the database (OBU),
report and label (RL), and program editor (PE) utilities.
Sam ples This option installs the sample files that are used in the various
hands-on lessons in the printed documentation. For example,
the tutorial in this guide for debugging a simple program using
the DOS-level debugger, CLD.LIB, assumes you have installed
the sample files. Choose this option if you plan to follow
through the DOS-level documentation examples.
DOS Help This option installs the Norton Guide Instant Access Engine and
the DOS-level online help databases, The Guide To CA-Clipper.
Moving On Once you have selected all of the components you wish to install,
simply click on the Install button. The CA-Installer will begin
the installation procedure, prompting you for any information
necessary. Simply follow the onscreen prompts to proceed with
the installation; CA-Clipper will be installed in the drive and
directory you specify.
2-8 CA-Clipper
lnstallation Procedures
From here, you have two options. You can either install all of the
components that are part of the CA-Clipper package (i.e., the full
installation) or select only those groups of components you know
you are going to need (i.e., a partial installation).
Full lnstallation For the full installation, simply press Enter as all groups are
selected by default.
The various groups are described below to help you decide what
you need to install. Nate that if you choose nat to install a
particular group at this time and later find that you need it, you
can always run the CA-Installer again and select only that group,
without affecting the rest of your current installation.
Minimum lnstallation The minimum installation far CA-Clipper is the System Files
group. This option will install all the system-defined libraries as
well as other components that are cornrnon to all DOS
applications.
System FUes This option installs the CA-Clipper compiler and all other system
files and libraries associated with CA-Clipper.
Utilities This option installs the files far the CA-Clipper database utility,
DBU.EXE; the report and label utility, RL.EXE; and the
DOS-level program editor, PE.EXE.
Sample Programs This option installs the sample files that are used in the various
hands-on lessons in the printed documentation far CA-Clipper.
Online Documentation This option installs the Norton Guide Instant Access Engine and
the DOS-level online help databases, The Guide To CA-Clipper.
2- l O CA-Clipper
The CA-Clipper Development Environment
Directory Description
\CLIP53 Master CA-Clipper
directory
\ CLIP53 \ BIN Executable (.EXE) and
batch (.BAT) files
\ CLIP53 \ CACI Dynamic link library
(.DLL) and other files used
by the Workbench
Continued
Getting Started 2- 11
The CA-Clipper Development Environment
Continued
Subdirectory Description
\CLIP53\CACI\DATA Repository files
\CLIP53\CACI\DATA \AUTOMAKE Files used for building
CA-Clipper applications
from within the
Workbench
\CLIP53\CACI\DATA \AUTOMAKE Used by the Workbench
\BACKUP build system to back up
files
\CLIP53\CACI\SAMPLES Workbench sample source
file s
\CLIP53\INCLUDE Header (.ch and .h) files
\CLIP53\LIB Library (.LIB) files
\CLIP53\NG The Guide To CA-Clipper
file s
\CLIP53\0BJ Object (.OBJ) files
\CLIP53\SOURCE Master directory for source
(. prg) files
\CLIP53\SOURCE\DBU Database utility source files
\CLIP53\SOURCE\PE Program editor source files
\CLIP53\SOURCE\RL Report and label utility
source files
\CLIP53\SOURCE\SAMPLE Sample program source
files
\CLIP53\SOURCE\SYS Subsystem source files
2-12 CA-Clipper
The CA-Clipper Development Environment
Environment Variables
The DOS environment variable definitions-INCLUDE, OBJ, and
LIB--are used by the compiler and linker when searching for
certain types of files. Each variable is set to the directory name
that contains the indicated file type. For example, SET
LIB=C:\CLIP53\LIB causes CA-Clipper to search for libraries in
the designated directory. This way, you do not have to include
the directory name when you want to link a library with your
application as long as the .LIB file is located in the LIB directory.
Getting Started 2- 13
Before Moving On
Before Moving On
Befare continuing on with the tutorial portions of this guide, you
must make sure your AUTOEXEC.BAT and CONFIG.SYS files
are updated with the necessary changes to operate in the
CA-Clipper development environment.
If, however, you did not allow the CA-Installer to add the
CA-Clipper directory to your AUTOEXEC.BAT path setting, you
will need to make these changes manually. You may also need
to adjust other settings befare starting CA-Clipper, depending on
your individual requirements.
AUTOEXEC.BAT If you did not allow the installer to make the changes far you,
you should add the fallowing lines to your AUTOEXEC.BAT file:
SET PATH=C:\CLIP53\BIN;%PATH%
SET OBJ=C:\CLIP53\0BJ;%0BJ%
SET LIB=C:\CLIP53\LIB;%LIB%
SET INCLUDE=C:\CLIP53\INCLUDE;%INCLUDE%
SET PIPEHANDLE=O
2-14 CA-Clipper
Before Moving On
FILES Option The recommended setting for the FILES option in CONFIG.SYS
is 60 or greater. For example:
FILES=60
Loading SHARE.EXE If you are using Windows version 3.10, it is necessary to load the
005 SHARE.EXE program to install file sharing and locking
capabilities on your system. To do this, include a line similar to
the following in your CONFIG.SYS file:
INSTALL=C:\DOS\SHARE.EXE /F:4096 /L:500
The values you specify for the /F and /L options will depend on
your system (see your DOS manual for details).
Swap File Size Depending on the amount of RAM in your system, you may
want to increase the swap file size. We recommend using a
swap file size at least as big as the amount of RAM you have,
and slightly more if possible. Far example, if you have 8 MB
RAM, you might want to consider a swap file size between 8 and
lOMB.
2-16 CA-Clipper
Starting the CA-Clipper Workbench
aa
•
- CA-Clipper
DBU Utilit~
~
Read Me
~
CA-Clipper Help
Summary
Now that you have successfully installed CA-Clipper, you
should read any other chapters in this book appropriate to your
level of expertise. Each has an introductory section to let you
know if it is for you. You are now ready to explore the
CA-Clipper development system.
ln This Chapter
The following topics are discussed in this chapter:
• How to compile and link your existing CA-Clipper
applications with CA-Clipper 5.3
• The immediate benefits of using the new version
• Suggested source code changes that take advantage of new
features
• Overview of the CA-Clipper Workbench
Runtime lssues
Several areas of code optimization have been added to the
CA-Clipper compiler, and one of them, shortcutting logical
expression evaluation, may affect how your program runs.
CA-Clipper takes a shortcut when evaluating complex logical
expressions linked with .AND. and .OR. by examining only as
much of the expression as necessary to determine the final result.
3-2 CA-Clipper
Compile. Link, and Go
Compiling
Although the compiler has been significantly improved
(including the addition of a preprocessor), you compile, as
always, by typing:
CLIPPER <sourceFile>
Linking
Linking with this version is slightly different because of the new
protected mode linker, CA-Clipper /Exospace, but the basic
syntax you use is the same:
EXOSPACE Fl MyFile LI MyLibs
Using RMAKE
The new make system, RMAKE.EXE, replaces MAKE.EXE, the
Summer'87 make system, and provides you with many new
features, but you can continue to use your old make files as
follows:
RMAKE <makeFile>.mak /U
This syntax tells RMAKE to look for a make file with a .mak
extension rather than the default (.rmk) and to treat the hash
symbol (#)as a comment indicator.
3-4 CA-Clipper
lmmediate Benefits
lmmediate Benefits
By simply compiling and linking your old programs with the
new version of CA-Clipper, you reap several immediate benefits,
including:
• LIM 4.0 compliance
• RSIS compliance
• Virtual Memory Management
• Graphic mode
RSIS Compliance
Graphic Mode
Note that the Light Lib Graphics API for graphic mode support
is included with this release.
3-6 CA-Clipper
Source Code Changes to Consider
One of the directives that you might want to consider using right
away is #define. In its simplest form, shown below, you can use
it to replace constant values with symbolic names:
#define <idConstant> <resultText>
IF LASTKEY() Esc
ENDIF
IF LASTKEY() Esc
ENDIF
3-8 CA-Clipper
Source Code Changes to Consider
At first glance this might seem futile. But when you consider
that for each memory variable you eliminate, you save at least 22
bytes of memory, it doesn't seem so fuhle anymore. Manifest
constants have no memory overhead as they are completely
resolved at compile time. This means that your executable file
will be smaller and will not require as much memory.
Additionally, since the variable names that you eliminate do not
have to be resolved at runtime, your program will run faster.
Use Pseudofunctions
Another use of the #define directive is to create pseudofunctions.
This form of #define is specified as follows:
#define <idFunction>( [<arg list>]) <exp>
FUNCTION SETVAR
PARAMETERS set, get
set = get
RETURN (set)
SETVAR(x, y)
3-1 O CA-Clipper
Source Code Chonges to Consider
SETVAR(x, y)
Getting Storted 3- 11
Source Code Changes to Consider
If you have taken the suggestions above and are using manifest
constants and pseudofunctions in your programs, consolidating
them into a header file that you #include in your source code
files will save you a lot of time and make you more productive.
Consider these points:
• Header files are reusable
• Header files can save numerous source code changes
• Header files make your programs more generic and modular
3- 12 CA-Clipper
Source Code Changes to Consider
In addition to creating and using your own header files, you can
also use the ones supplied with CA-Clipper. If you use the
command or function for which the header file is designed, your
programs will be more readable and maintainable when you
#include the appropriate header file and use symbol names
instead of constants.
For example, in Summer '87 you might have used the following
to open a file with read/write access:
nHandle = FOPEN ( "Temp. txt" , 2}
3- 14 CA-Clipper
Source Code Changes to Consider
Other(a}
RETURN (result}
Other(a}
RETURN (result}
If, on the other hand, your Surnrner '87 code is nat so nicely
structured, the function rnight look like this:
FUNCTION Durnmy
PARAMETERS a, b, c
Other ()
RETURN ( result)
3- 16 CA-Clipper
Source Code Changes to Consider
Static variables can also have filewide scope if you declare them
at the beginning of your .prg file before any other function or
procedure declarations. Filewide statics are visible to all
routines defined in the .prg file and are available as long as the
application is running.
In general, if you do not rely on the fact that publics are inherited
outside of the current .prg file, you can make this change. lf you
rely on this inheritance property, the change will not be possible
without significant program restructuring.
3-18 CA-Clipper
Source Code Changes to Consider
Declare Everything
Two statements, FIELD and MEMV AR, allow you to declare lists
of variable names to the compiler. The special aliases, FIELD->
and MEMVAR->, let you qualify variable names in your code
without making declarations.
Finally, after you have declared everything, you can use the /W
option to check for undeclared variable references. This option
causes the compiler to generate a warning message for each
undeclared and unaliased variable name in your program. In
addition to showing you variable names that you forgot to
declare, this option may also indicate areas of your program
where you inadvertently misspelled a variable name.
With CA-Clipper, you can make your library more modular and
readable by breaking out reusable code into static routines that
are called by the end-user functions. When your library is linked
into an application, the user will not stumble onto the service
routines inadvertently since you declared them to be static.
3-20 CA-Clipper
Source Code Chonges to Consider
<function statements>
RETURN (lSuccess)
FUNCTION Two
PARAMETERS x, y, z
<function statements>
RETURN (nValue)
RETURN
RETURN
FUNCTION One(a, b, c)
<function statements>
RETURN (lSuccess)
FUNCTION Two(x, y, z)
<function statements>
RETURN (nValue)
RETURN
PROCEDURE z57936abc
* Service routine to restore environment
<procedure statements>
RETURN
3-22 CA-Clipper
Source Code Chonges to Consider
FUNCTION Printlt
PARAMETERS a, b, c
* save environment
DO z57935abc
<function staternents>
* restore environment
DO z57936abc
RETURN (lSuccess)
RETURN
RETURN
FUNCTION Printit(a, b, c)
SaveEnv() li save environment
. <function staternents>
The main difference between macros and code blocks is the time
at which they are compiled. Macros are compiled "on the fly" at
runtime, whereas code blocks are compiled at compile time
along with all other program code. The fact that there is nothing
to figure out about code blocks at runtime is what makes them
execute faster than macros. Since code blocks effectively break
the single compile and run function of the macro operator into
two discrete steps, you save execution time especially in cases
where a macro is evaluated repeatedly.
3-24 CA-Clipper
Source Code Changes to Consider
To evaluate the compiled code stored ina code block, use the
EVAL() function:
EVAL( <bBlock>, [<BlockArg list>]) ~ LastBlockValue
SKIP
ENDDO
CLOSE
RETURN
SKIP
ENDDO
CLOSE
RETURN
3-26 CA-Clipper
Source Code Changes to Consider
The fallowing CA-Clipper code does the same thing as the above
example using an array instead of a database file. Of course, just
as you had to create the database file far use with the Summer
'87 program, you have to create the array far use with the new
menu function. This example includes the array declaration and
initialization:
#include "menusubs.ch" li contains subscript
li names for menu array
LOCAL aMenu[3, 5]
aMenu[l, ME_X] := 6
aMenu[l, ME_Y] := 10
aMenu[l, ME_PROMPT] := "Add"
aMenu[l, ME_MESSAGE] := "New Acct"
aMenu [ l, ME_FUNCTION] . - " { I I NewAccount (} }"
aMenu[2, ME_X] := 7
aMenu[2, ME_Y] := 10
aMenu [ 2 , ME_PROMPT] : = "Edi t"
aMenu[2, ME_MESSAGE] := "Change Acct"
aMenu[2, ME_FUNCTION] := "{ I I ChangeAccount(} }"
aMenu[3, ME_X] := 9
aMenu[3, ME_YJ := 10
aMenu [ 3 , ME_PROMPT] : = "Exi t"
aMenu[3, ME_MESSAGE] := "Return to DOS"
aMenu [3, ME_FUNCTION] . - " { 11 WrapUp () } "
Menu(aMenu)
FUNCTION Menu(aOptions)
LOCAL i, nChoice, bFunc
SET WRAP ON
SET MESSAGE TO 23 CENTER
DO WHILE .T.
FOR i := 1 TO LEN(aOptions)
@ aOptions[i, ME_X], aOptions[i, ME_Y]
PROMPT aOptions[i, ME_PROMPT] MESSAGE
aOptions; [i, ME_MESSAGE]
NEXT
MENU TO nChoice
DO CASE
CASE nChoice = O
RETURN NIL
OTHERWISE
bFunc = &(aOptions[nChoice,;
ME_FUNCTION])
ENDCASE
EVAL(bFunc)
ENDDO
3-28 CA-Clipper
An Overview of the Workbench
The Repository
In the CA-Clipper Workbench, applications, modules, and
entities are stored ina repository. Source code files are stored
outside the repository on disk.
3-30 CA-Clipper
The Workbench Tools
Within this single desktop, you can access almost any of the
Workbench's features from any window at any time. You can
also open and simultaneously work with multiple windows and
editors.
Visual Editors Many of the editors in the CA-Clipper Workbench are visual.
Their point-and-click, drag-and-drop design approach and
WYSIWYG environment allow you to develop an application
visually, thereby improving the quality of the application and
reducing the total development time.
For example, to add GUI controls (!ike check boxes or list boxes)
to a form using the Form Editor, you simply click on an icon ina
tool palette and click in the form to place it. You can then
manipulate and define the control as desired (for example,
resize, change colors and fonts, or add code to handle events).
Generating Code When you are finished designing in any of these editors and
have saved your work, the CA-Clipper Workbench generates
powerful and straightforward code based on the underlying
classes in the CA-Clipper language, such as CheckBox, ListBox,
and TopBarMenu.
3-32 CA-Clipper
The Workbench Tools
The Browsers
Browsers provide a convenient and organized way to view the
data that is currently stored in your repository. In the
CA-Clipper Workbench, you can browse:
• Applications
• Modules
• Entities
• Errors
Application Browser
3-34 CA-Clipper
The Workbench Tools
Note: You will soon see that you can have many different
Module, Entity, and Error Browsers open at the same time.
However, there is only one Application Browser.
Module Browser
Entity Browser
3-36 CA-Clipper
The Workbench Tools
3-38 CA-Clipper
The Workbench Tools
Error Browser
The Editors
The CA-Clipper Workbench provides the following types of
editors:
Editor Creates
Source Code Source code entities, like functions and
Editor procedures
DB Server Editor Data server entities
FieldSpec Editor Field spec entities
Form Editor Form entities (like data forms and dialog
boxes)
Menu Editor Menu entities (like menus and shortcut keys)
3-40 CA-Clipper
The Workbench Tools
The DB Server Editor The Workbench provides the DB Server Editor that lets you
create and modify data servers. A data server is a high-level,
abstract entity designed to give you a consistent interface for
your database. The DB Server Editor creates data servers based
on the traditional Xbase model of a database file. It does not,
however, physically change any database files on disk.
3-42 CA-Clipper
The Workbench Tools
The FieldSpec Editor In many cases, the different data servers your application uses
contain similar, if nat identical, fields (far example, all zip code
fields are typically the same, regardless of where they are used).
You can either define the properties of these common fields
(such as validation and farmatting rules) each time you create a
new data server, or you can create a single field specification and
reuse it in each data server that needs it.
Form Editor
The Form Editor is used for the internctive design of the various
farms of your application.
Tool Palette To design these farms, the Form Editor features a floating tool
palette. To place a control on a farm (such as a push button, list
box, or radio button group), just click on a button in the tool
palette and click in the form.
You can then go on to define properties for your forms and the
various controls you place on them (for example, you may want
to specify the text that should appear in the status bar when a
farm or control is selected).
Controls and Actions One important property of certain controls is an action type. This
is because certain types of controls initiate actions (for example,
when the user clicks the OK button in a dialog box, the program
processes the information entered in the dialog box and closes
it).
The Form Editor makes it easy for you to associate actions with
these types of controls by allowing you to specify an action type
as property. You have the option of using either a predefined
action or a custom function call.
There are many different types of controls that you can define in
the Form Editor, but before going on to describe them, a few
words about data forms are in order.
When you link a form control to a field, you are actually linking
it with the field specification associated with that field-the
control, therefore, automatically inherits and uses all of the field
specification's properties (for example, its validation and
formatting rules).
3-44 CA-Clipper
The Workbench Tools
For instance, here is the DISKCAT data form that you will create
in the next chapter using the Auto Layout feature:
Tool palette
10 15 20 25 30 35 40 45
Disk Data
Captions and controls
created for each fleld
Id: lxxxxxxl
Title: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
10
15
Worksf)bee name
Chent area tOfegrOl.l"ld coloi Black
Cijeni area background colOf \.I/hite
Properties window
Types of Controls The tool palette in the Form Editor contains a host of buttons
representing different graphical user interface (GUI) controls.
(If you prefer, the Form Editor also features an Edit Select from
Palette menu command, which allows you to place controls by
choosing commands from a menu.)
Let' s briefly review the types of controls that you can place on
your forms using the tool palette in the Form Editor. (If you
prefer, the Form Editor also features an Edit Select from Palette
menu command, which allows you to place controls by choosing
commands from a menu.)
Check Boxes Check boxes indicate a set of options that are either on or off. If
more than one check box is present on a form, the user can select
as many as are applicable. The state of a check box is indicated
in the box to its left. If there is an X in the box, it is selected;
otherwise, it is not.
Combo Boxes Combo boxes are list boxes with a single-line edit control
attached at the top. The user can either type a value directly into
the edit control, or click on the Down arrow button to the right to
open a list box from which to make a selection. The selection is
used to fill in the edit control, which can then be edited.
In a data entry form, you can use a combo box instead of a list
box when the field value has more possibilities than you care to
list. By placing the most commonly used values in the associated
list box, you give the user a quick way to make a selection
without removing the flexibility of entering values that are not
listed. Shown here is an example from the Workbench's
Browsers Font dialog box:
Ari a I
ii AvantGarde
ii Bookman
ii Courier
'lf Courier New
3-46 CA-Clipper
The Workbench Tools
Fixed Text Fixed text displays a caption or label anywhere within a form. A
common use of this type of control is to create a caption for a
single-line edit control, a feature that is utilized by the Form
Editor' s Auto Layout feature. Below is an example from the
Workbench's System Options dialog box:
Path for CA-Clipper EXE Files:
IC: \CLIP53\CACl\DA TA
Frames Frames visually indicate a set of related controls. They provide a
caption to describe the controls, but serve no other purpose.
They are most often used to display a group of related check
boxes. Below is an example from the Workbench's System
Options dialog box which allows you to choose various system
default options:
System Default Options---~
List Boxes List boxes display a list of choices to the user and allow the user
to scroll through them and select one. In a dialog box, you might
use list boxes to allow the user to select a file name and a path.
On a data entry form, you might use a list box to display all
possible values for a particular field. This example is from the
W orkbench' s Browse dialog box:
12::> c:\ •t:
12::> clip53
Bcaci
bdata
LI automake
Push Buttons Push buttons react when the user chooses them by generating an
event. Some examples of push buttons are the standard OK and
Cancel push buttons, shown below, used to close a dialog box:
Radio Button Groups Radio button groups visually indicate a group of radio buttons.
Like a frame, they provide a descriptive caption for the controls
they contain, but they have another special purpose-only one
of the radio buttons within a radio button group can be selected
at a time. When the user chooses a new radio button in the
group box, the previously selected one is deselected.
Radio button groups let you use radio buttons to present a set of
choices to the user. The following example from the
Workbench's Link Map Options dialog box allows you to sort
public symbols either by address or by name:
Sort Properties--------.
@ Publics Sorted Bv Name
O Publics Sorted Bv Address
Single-Li ne Single-line edit controls are probably the most commonly used
Edit Controls controls on data entry forms and are often used to represent
fields into which the user may type almost any value:
A single-line edit control
Subforms Subforms are simply data forms that you place on other data
forms as controls. Typically you would use a subform to show a
master-detail relationship between two related data servers. For
more information, refer to Data Forms in the "Using the Form
Editor" chapter of the Workbench User Guide.
3-48 CA-Clipper
The Workbench Tool
Menu Editor
Auto Layout First of all, like the Form Editor, the Menu Editor features an
Auto Layout feature. In the Menu Editor, however, Auto Layou1
is used to add one or more predefined, standard menus to an
application. For example, at the touch of a button, you can add
File, Edit, View, Window, and Help menus to your application.
In addition, each of these predefined menus (like File) contains a
set of default menu items (for example, New, Open, and Save),
for which default properties are already supplied, including
action types.
For example, the following shows the properties initially set for
the predefined File Open menu command:
Shortcut key
lnit. enabled Yes
lnit. checked No
Menu item ID
Auto Layout provides a quick way to get started with your menu
structures-you can use the resulting menus as is, or you can
customize them as desired to fit your application. Of course, you
can easily create your own custom menu structures in the Menu
Editor.
Menu ltems The various types of menu items that you can include ina
menu's structure are illustrated in the Workbench example
below:
Menu name
Menu commands:
New ...
Norma I Qpen Enter Shortcut key
Save Repository
Grayed ----+-
Q.elete Dei
Ren.11.me ... .+--- Separator
Import„.
fxport.„ lndicates another menu level (submern
f!rint. .. Ctrl-tP
Print Setup ...
Sel!!P . .Eonts„.
!;.olors
E~it AIHF4
Default .!.inker Options ...
Q.efault Compiler Options ...
System Qptions.„
§.ave Desktop
Submenu
Ellipsis indicator
3-50 CA-Clipper
The Workbench Tools
The Debugger
The Workbench's debugger provides advanced tools for tracking
and correcting errors that occur at runtime. For example, you
can:
• Use one of several execution modes to control the execution
of your application while viewing the source code in the
Debug source code window
• Evaluate and trace expressions
• Set, reset, and clear breakpoints
• View and modify variables
• Create watch expressions
• View the call stack
• View database and other work area information in a
separate window and modify database field values
• View and modify system settings
Summary
In this chapter, you have seen a high-level overview of many
new CA-Clipper features and their benefits. Some of the benefits
require a fair amount of work to achieve and may or may not be
worth your while, but the important thing to keep in mind is that
you will get substantial benefits immediately by simply
compiling and linking with the new version.
Many of the topics presented in this chapter are complex and are
not fully explained. Also, the list of topics discussed is by no
means exhaustive (see the "Introduction" chapter of this guide
fora complete list of new features). There are probably other
areas of program improvement that might be beneficial to you,
and certainly there are many more new features for you to take
advantage of when doing new development. For additional
information regarding any topic in this guide, there are a
number of places that you can look.
3-52 CA-Clipper
Summar)
ln This Chapter
This chapter walks you through the process of creating and
executing a simple CA-Clipper application using the various
tools provided by the CA-Clipper 5.3 Workbench. If you have
never used a GUI interface before or are simply new to
CA-Clipper, just follow the easy, hands-on lessons in the tutorial.
Application Browser
Clicking this button is the same as choosing the File New menu
command:
Qpen Enter
Save Repository
Qelete Dei
Ren_!!me ...
lm po rt ...
.E_xport...
.E'rint. .. Ctrl+P
Print Setup ...
Sel_!!p
Ei!;il Alt+F4
4-2 CA-Clipper
LESSON l: Creating on Application
Application button
In the next lesson you will create the first entity for the Binary
Objects module.
Menu Terms A menu is a user interface element that presents a list of choices.
Menus appear in a window' s menu bar. For example, below is
the Workbench's menu bar:
Selected pull-down menu
I
Menu bar
4-4 CA-Clipper
LESSON 2: Adding a Menu Structure
Menu ltems The various types of menu items that you can include in a
menu's structure are menu commands, shortcut keys, submenus,
separators, etc. which were discussed in the previous chapter.
Workspace Overview The Menu Editor is the primary workspace in the Workbench for
creating, viewing, and modifying menu structures:
Menu Editor window
Properties window
Notice that the Menu Editor has its own toolbar, status bar,
floating Properties window, and area for previewing defined
menus.
4-6 CA-Clipper
LESSON 2: Adding a Menu Structure
Action
Message on status bar
Shortcut key
lnit enabled Yes
lnit checked No
Menu itemlD
Vertical position o
Horizontal position o
Width 79
Unselected items foreground Yellow
Unselected shortkeys foreground Bright Cyan
Disabled items foreground Gray
Unselected items background Blue
Selected items toreground Yellow
Selected items background Black
Border foreground Gray
Border background Blue
4-8 CA-Clipper
LESSON 2: Adding a Menu Structure
Menu item
(3-D bar format)
4-1 O CA-Clipper
Lesson 2: Adding a Menu Structure
Notice also that File and Edit have been added automatically to
the Menu Editor' s preview menu bar. This prototypical menu bar
is partially operational-showing description messages in the
status bar and allowing submenus to be pulled down-but
nothing actually happens when you make a selection. Its
purpose is to provide you with visual feedback while you are
designing a menu structure.
Now, you need to define the pull-down menu items that will go
under the File and Edit menus just created. To do this, you must
use the Menu ltem Properties window:
System menu
Action
Message on status bar
4- 12 CA-Clipper
Lesson 2: Adding a Menu Structure
Far the purposes of this tutorial, your File menu needs only one
menu item-an "Exit" menu command. To insert a menu item
hierarchically under the File menu:
1. Click on the 3-D bar titled "File."
2. Select the Insert Child command from the Edit Insert Item
menu.
This opens up a new edit control that is indented, indicating
that it is a child, or submenu, of File:
Expand/Collapse (+I-) button
4-14 CA-Clipper
Lesson 2: Adding a Menu Structure
Now let' s add the following menu items for the Edit menu:
"Top," "Bottom," "Next," and "Previous" menu commands, and
a separator.
Top Menu Command To add the first menu command, Top, under the Edit menu:
1. Click on the "Edit" 3-D bar.
2. Select the Insert Child command from the Edit Insert Item
menu.
A new edit control and Properties window appear.
3. In the new Menu Item Properties window, enter Top in the
value cell for the Caption property.
4. Enter DiskDispTest(DBGOTOP()) in the value cell for the
Action property.
This is the function call to be performed when this menu
item is selected. You will associate the function with the
form later in the tutorial using the Form Editor.
5. For the Message on Status Bar property, type Go to the first
record in the database, and press Enter.
6. Click on the Shortcut key property value cell.
The Shortcut Keys dialog box appears, allowing you to
define a shortcut key.
7. Select Ctrl in the Key Modifier group box and HOME from
the Key drop-down list box:
8. Choose OK.
You are returned to the Menu Editor. Notice that the
shortcut key value is added by the system to the Menu Item
Properties box:
Bottom Menu Now add the Bottom menu command and specify its property
Command values:
l. With the cursor in the Top edit control, select the Insert
Sibling command from the Edit Insert Item menu:
The Insert Sibling command creates a new edit control at the
same, or sibling, level as the Top menu command:
4- 16 CA-Clipper
Lesson 2: Adding o Menu Structure
Seporotor To separate the Top and Bottom menu commands logically and
visually from the Next and Previous menu commands, simply
choose the Insert Separator command from the Edit Insert Item
menu while the cursor is still in the Bottom edit control. The
CA-Clipper Workbench automatically adds a separator to your
menu structure:
Separator
Next Menu Now add the Next menu command and specify its property
Command values:
l. With the cursor in the Separator edit control, select the Insert
Sibling command from the Edit Insert Item menu.
A new edit control and Properties window appear.
2. In the new Menu Item Properties window, enter Next in the
value cell for the Caption property.
3. Enter DiskDispTest(DBSKIP()) in the value cell for the
Action property.
This is the function call to be performed when this menu
item is selected. You will associate the function with the
form later in the tutorial using the Form Editor.
4. For the Message on Status Bar property, type Go to the next
record in the database, and press Enter.
5. Click on the Shortcut key property value cell.
The Shortcut Keys dialog box appears.
6. Select Ctrl in the Key Modifier group box and N from the
Key drop-down list box.
7. Choose OK.
8. You are returned to the Menu Editor.
Previous Menu Finally, add the Previous menu command and specify its
Command property values:
l. With the cursor in the Next edit control, select the Insert
Sibling command again.
A new edit control and Properties window appear.
2. In the new Menu Item Properties window, enter Previous in
the value cell for the Caption property.
3. Enter DiskDispTest(DBSKIP(-1)) in the value cell for the
Action property.
This is the function call to be performed when this menu
item is selected. You will associate the function with the
form later in the tutorial using the Form Editor.
4- 18 CA-Clipper
Lesson 2: Adding a Menu Structure
Notice that all entries are at the same menu level and,
consequently, all appear in the preview menu bar as menus.
4-20 CA-Clipper
Lesson 2: Adding a Menu Structure
If you click on "File" in the preview menu bar, you can view the
File pull-down menu you just created:
Top Ctrl+HOME
Bottom Ctrl+END
Next Ctrl+N
Previous Ctrl+P
All of the actions that were just entered into the Menu Item
Properties window represent the actions that will take place
when that particular menu item is selected by the user. For
example, when the Top menu item is chosen, the DiskDispTest()
function will be run after performing a DBGOTOP().
The CA-Clipper Workbench has now created all the source code
that is needed fora complete menu structure. Your pull-down
menu structure has been saved as a menu entity in the Binary
Objects Module, and a DC_MENU_PRG module with the source
code has been generated automatically.
In the next lesson you will leam how to use the DB Server Editor
to create a data server entity.
4-22 CA-Clipper
LESSON 3: Creating a Dota Server and Field Specs
Selected module
4-24 CA-Clipper
LESSON 3: Creating a Dota Server and Field Specs
The Import dialog box closes, and the File Name edit control is
updated with the name and path of the associated database file.
By default, the name of the .dbf file is also used for the name of
the data server, as well as the DB Server Editor' s title bar:
Database fields
• Note: You can exclude a field from your data server definition,
if you wish, by clicking on it and then clicking on the Right
arrow button. This will move the specified field to the Exclude
list box.
Name ID
Fieldspec DISKDATA_ID
Message on status bar .
Type Numeric
Length
Decimah
Picture
Min length
Required No
Minimum
Maximum
Validation
Notice that some property values are already filled in, such
as Name, FieldSpec, and Type. The property values of the
existing database fields default automatically to the
corresponding property value cells in the Properties window
of the data server that is being associated with that database
file. For example, the default FieldSpec name is
<DataServerName> _<FieldName>, or DISKDATA_ID in this
instance.
2. Click in the Message on Status Bar value cell and type
Unique ID number for this disk.
1-26 CA-Clipper
LESSON 3: Creatinp a Dota Server and Field Specs
3. Replace the default value "S" with 6 in the Length value cell.
Note: All default values can be modified.
4. In the Picture value cell, enter 99,999.
This is a standard Xbase picture clause used to format this
field.
5. In the Minimum value cell, type 1.
6. In the Maximum value cell, type 99999.
TITLE Field Ina similar manner, let' s define the properties for the TITLE
field:
1. Click on the TITLE field name in the Include list box.
A new FieldSpec Properties window appears.
2. Click in the Message on Status Bar value cell and type Title
for this disk.
CAPACITY Field Now, let's enter the properties for the CAPACITY field:
1. Click on the CAP ACITY field name in the Include list box.
A new FieldSpec Properties window appears.
2. Click in the Message on Status Bar value cell and type
Storage capacity for this disk.
The other default properties are fine as is.
SIZE Field Finally, enter the properties for the SIZE field:
1. Click on the SIZE field name in the Include list box.
A new FieldSpec Properties window appears.
2. Click in the Message on Status Bar value cell and type Size
of disk.
3. In the Validation value cell, type DISKDATA->SIZE =
'3 1/2' .OR. DISKDAT A->SIZE = '5 1/4'.
Notice that there are now six entities in the Binary Objects
module. If you open the Binary Objects module by
double-clicking on it, you can view these entities in a
module-specific Entity Browser:
In addition to the menu entity you created earlier far your menu
structure, there is now a server entity far the DISKCAT data
server just created and faur field spec entities far its
corresponding fields.
Now let' s create a farm far DISKCAT that utilizes the DISKCAT
data server you just defined.
a-28 CA-Clipper
LESSON 4: Using the Form Editor
Creating a Form
To access the Form Editor and create a data form:
1. First, close any window(s) still open from the last lesson.
You are returned to the Module Browser for DISKCAT.
Workspace Overview The Form Editor is the primary workspace in the Workbench for
creating, viewing, and modifying forms:
Status bar
Client area
Properties window
Notice that the Form Editor has its own toolbar, status bar, client
area, tool palette, and Properties window.
l-30 CA-Clipper
LESSON 4: Using the Form Editor
Dota Server Property 4. Click on the value cell for the Data Server property in the
Form Properties window.
A drop-down list box appears:
Workspace name
Client area roreground colo1
Client_ area background color
Border foreground color
Border background colm
Status !ine
Caption
5 10 15 20
4-32 CA-Clipper
LESSON 4: Using the Form Editor
3. Choose OK.
The Form Editor should now look like this:
s 10 lS 20 2S 30 3S 40 4S so ss
--~-t---~--+-----l-----+------l------t
s Id:
Ti t 1 e : XXXXXXXXXXXXX:,:XXXXXXXXXXXXXXXXXXXXXXXXXX
10
capacity: jxxxxxxx\
15
size: Ixxxxx I
Caplion ld
Message on status bar Unique ID numbe1 IO! lhis disk
Field spec DISKDATA_ID
Entry t_ype Edit
Caption foreground color Black
Caplion backg1ound color White
Aclive edit lo1eg1ound color B1ight Red
.ll.clrve edit backg1ound colo1 White
lnactive edit foreground color Black
lnaclive edil backg1ound colo1 While
Frame around entr_y area Yes
Memo peisrslenl No
Delault value lo1 lield
Addilional enli~ lield p1ope11ies
2. In the value cell for the Default Value for Field property,
enter DISKDAT A->ID.
This ensures that the data that is in the database is displayed
immediately when the form is opened.
3. Click on the single-line edit control labeled "Title."
A new Entry Field Properties window appears.
4. In the value cell for the Default Value for Field property,
enter DISKDATA->TITLE.
4-34 CA-Clipper
LESSON 4: Using the Form Editor
5 Id:
Title: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
10
_Capacity: - - -
Choice
Choice
15 Choice
4. In the value cell for the Default Value for Field property,
enter ALL TRIM( DISKDATA->CAPACITY ).
4-36 CA-Clipper
LESSON 4: Using the Form Editor
Since you want specific capacities as your actual choices for the
Capacities list box, you need to customize this particular list box
control. To do this:
1. Click on the value cell for the Additional Entry Field
Properties, and then click on the Ellipsis button that is
displayed.
The Multiple Choice Field Data dialog box appears:
4-38 CA-Clipper
LESSON 4: Using the Form Editor
11. Type 720K in the blank Displayed Text edit control and
leave the Field Contents as <Auto>.
12. Choose the Update >> push button.
13. Similarly, create two new array items and define their text as
1.2MB and 1.44MB, respectively.
14. Choose OK.
5 10 15 20 25 30 35 40 45 50 55 60
Disk Data
5 .Id:
.Title: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
10
: t:'a.pacity:·~·--~\
300K
360K
600K
15 720K
Sizing hondles
The Capacity field now displays a scrollable six-line list box that
presents all of the different disk capacities that are currently
available. The user of the DISKCAT application will be able to
click on one of these choices, thereby greatly enhancing the
speed with which he or she works.
Tip: In order to save space, you may change the size of the
list box that is displayed in the farm by clicking once on it to
activate it, and then clicking on the sizing handles to resize
the list box control. Do nat worry if all six items do nat
appear in the farm. When the code far this farm is
generated, the CA-Clipper Workbench will automatically
place a scroll bar on the list box.
Now you need to display a list of user choices far the size of a
disk. In this case, the best type of control is nat a list box but
rather a radio button group that presents the user with mutually
exclusive choices. The user will be able to select one size or the
other, but nat both.
4-40 CA-Clipper
LESSON 4: Using the Form Editor
The Form Editor now reflects the changed control for the Size
field:
Since you want to present specific sizes as your actual choices for
the Size radio button group, you need to customize this
particular control. To do this:
1. Click on the value cell for the Additional Entry Field
Properties, and then click on the Ellipsis button that is
displayed.
Again the Multiple Choice Field Data dialog box appears.
2. In the Number of Items edit control, change the value to 2.
3. Select Choice 1 in the List of Items list box by clicking on it.
4. Replace "Choice 1" in the Displayed Text edit control with
31/2 and leave the Field Contents as <Auto>.
5. Choose the Update >> push button.
4-42 CA-Clipper
LESSON 4: Using the Form Editor
The Size field now displays a radio button group that presents
the user of DISKCAT with two disk sizes, allowing him or her to
toggle between these choices.
Push button
Blltton
xxxxxxxxx
10+----~
Button8
300K
360K Button
15 600K 5 1/ 4 Foreground color when button is pressed Black
Backgrol.l'ld color when button is pressed 'w'l"Wte
Foregro1..md color when but!on is released Black
Background color when button is released ~e
Button style
Action type when button pressed Cancel
Custom functioo call
Caption Button
Foreground color when button is pressed Black
Backg1ound color when button is pressed White
Foreground color when bulton is released Black
Background color when button is 1eleased White
Foreground color when button has no focus Black.
Background colm when button has no focus White
Button slyle
4-44 CA-Clipper
LESSON 4: Using the Form Editor
_Disk Data
Id: Save
Capacity: ~-~
300K New
360K
15 600K
Delete
Befare leaving the Form Editor, however, you need to specify the
control order far tabbing.
4-46 CA-Clipper
LESSON 4: Using the Form Editor
Title
Button9 "Done"
Capacity
Size
ButlonlO
Buttonl 1
This dialog box displays the names of all the controls, as well
as their captions and control types, in tab stop order as they
appear in the source code.
2. Click on a control name (for example, Title).
3. Use the Up or Down arrow button to change its control order
appropriately.
4. Repeat steps 1 and 2 until the Control Order dialog box
reflects the desired order:
"Capacity:" (5 ingleline
"Save" (Pushbutlon)
"Done" (Pushbutlon)
"New" (Pushbutton)
"Delete" (Pushbutton)
5. Choose OK.
You are returned to the Form Editor.
Let' s close the Form Editor and return to the Module Browser for
DISKCAT. Notice that there are now seven entities in the Binary
Objects module:
New modules
The newest entity is the Disk Data form you just created. Notice
also that there are two new modules: DISKDISPLAY_CH and
DISKDISPLAY_PRG. Each of these modules contains the source
code that was generated by the Form Editor when you saved the
Disk Data form and exited the Form Editor. The
DISKDISPLAY_CH module contains the header, or include, file
and the DISKDISPLAY_PRG module contains the procedural
code.
4-48 CA-Clipper
LESSON 5: lmporting an External File
lmporting DC_UTILS.PRG
To import the DC_UTILS.PRG external file:
1. First create a new module by clicking on the New Module
toolbar button:
New Module toolbar button
4. Choose OK.
A standard Open dialog box appears:
New module
Note that the file name of the imported program (.prg) file has
been used by default for the name of the new module. You can,
of course, rename it, if you wish, using the File Rename Module
menu command.
4-50 CA-Clipper
LESSON 5: lmporting on Externol File
Accessing the 2. To view the actual code within the module, double-click on
Source Code Editor the 3-D bar labeled DC_USEFILES. The Source Code
Editor appears displaying the text block and the
DC_USEFILES() function:
Text block
"DBP'NTX", "DISKDATA")
ENDIF
DB SET INDE X ( "DISKID .NTX")
Function
DBSELECTAREA ( l)
RETURN .T.
Now that you have just leamed how to access the Source Code
Editor, in addition to importing an extemal file, let us proceed to
the next lesson, which will show you how to modify code using
the Source Code Editor.
4-52 CA-Clipper
LESSON 6: Using the Source Code Editor
Workspace Overview The Source Code Editor is the primary workspace in the
Workbench for viewing, creating, and modifying source code
entities:
Toolbar
"DISKDATA"'J
Status bar
Notice that the Source Code Editor, like the other editors, has its
own toolbar and status bar.
4-54 CA-Clipper
LESSON 6: Using the Source Code Editor
#include "button.ch"
#J.1~c1ude
"inkey.ch"
Note: Use the scroll bar to view the entire function. You can
also click on the Source Code Editor' s Maximize button to
increase the viewing area.
MSETCURSOR ( . T. )
CLS
MEMVAR->olnfo==DC_MENUCreate()
4-56 CA-Clipper
LESSON 6: Using the Source Code Editor
DiskDispClose ( aTest
MSETCURSOR( lMouse )
RETURN ( NIL )
Once these changes have been made to these two source code
files, you are just about ready to build the application.
1; /
1-58 CA-Clipper
LESSON 6: Using the Source Code Editor
4-60 CA-Clipper
LESSON 7: Compiler and Linker Options
4-62 CA-Clipper
LESSON 7: Compiler and Linker Options
Building an Application
4-64 CA-Clipper
LESSON 8: Building and Executing DISKCAT
Executing on Application
Executing DISKCAT After the build is successfully completed, you can run the
DISKCAT application.
Notice that the Clipper Batch File Path and Name edit
control is automatically filled in.
Note: See Executing an Application in the "Working in the
Workbench" chapter of the Workbench User Guide for more
information about defining your CA-Clipper runtime
environment.
2. Choose OK.
Viewing DISKCAT If you now select one of the Edit menu commands, you can view
and use DISKCAT:
4-66 CA-Clipper
Summary
Summary
In this tutorial, you have seen how simple it isto create a
CA-Clipper application using the various tools provided by the
CA-Clipper Workbench. You have used the DB Server Editor to
prepare data files to be accessed by a form, the Menu Editor to
create a complete menu structure, and the Form Editor to
generate data entry forms. You have also used the Source Code
Editor to amend the code that is generated automatically by the
Workbench when you created the data server, menu, and form
entities. Finally, you have set the compiler and linker options for
an application, built it, and executed it.
ln This Chapter
The program that you created in the previous chapter was
purposefully over-simplified to demonstrate the features of the
W orkbench without bogging you down in the details of the
CA-Clipper language. The programs that you will write,
however, are likely to be much more complex and will, therefore,
run the additional risk of errors.
CA-Clipper offers two tools to help you find and correct errors in
your applications: the Workbench debugger, and the 005-level
debugger. This chapter walks you through the process of
debugging another simple program using the DOS debugger,
CLD.LIB. It is intended only as an introduction to the debugger
and some of its many features. Far a full description of all the
DOS-level debugger features, refer to the "CA-Clipper
Debugger-CLD.LIB" chapter in the Programming and Utilities
Guide .
Getting Started 5- l
Requirements for This Chapter
You will also need to access the da tabase file, Sales.dbf, and the
index file, Salesrep.ntx, in order to run the sample program.
The fields required in Sales.dbf are Salesrep (character) and
Amount (numeric), and the index key for Salesrep.ntx is
Salesrep.
Finally, this chapter assumes that all files you create (.prg, .dbf,
.ntx, etc.) are in the current directory. Otherwise, the utility
programs and libraries, such as PE.EXE and CLD.LIB, and the
sample program that you will create may not be able to locate
the needed files.
5-2 CA-Clipper
Creating a Program with Errors
5-4 CA-Clipper
Executing Your Program Using the Debugger
I O
cOldSal-n := Sales->Sdes
DO 1.HILE cOldSal-n = Sales->Salesrep
'? Sales->Salesrep. Sales->Allount
nToto.l~nt •= Sales->Allount
SICIP
El'IDllO
19: '?"Tato.I:", nTotal~. "for", cOldSal-n
11: ĐtDDO
12: CI.OSE Sa les-o
13:
14:
15:
16:
F1 llelp fZ Zoon FJ Rtptat f1 Lisce FS Go F& lJA F7 Here fD Step f3 BJ;Pt flO Trctce
Fl-Help F2-Zoon F3-Repeat F4-User FS-Go F6-WA F7-Here F8-Step F3-BkPt FlO-Trace
5-6 CA-Clipper
Executing Your Program Using the Debugger
Notice that the far right window pane shows a list of all the
field names in Sales.dbf. As you can easily see, there is no
field named Sales. Thus, there is a typographical error in the
line of code that caused the error. The field name Sales
should have been Salesrep.
2. Press Esc.
The View Workareas window closes and retums control to
the main debugger screen.
5-8 CA-Clipper
Starting the Next Debugger Session
Fl-Help FZ-Zoorn F3-Repeat F1-User FS-Go Fo-WA f7-Here FB-Step F9-BkPt FlO-Trace
To make sure that the change worked and to see if there are any
more errors in the program, you are going to run the new
version of the program using the debugger.
5- 1O CA-Clipper
Starting the Next Debugger Session
Setting Watchpoints
This line of code seems okay when you first look at it. It simply
adds the amount ina database field to a variable and assigns the
new value back to the variable. To find out what the problem is,
you can set up watchpoints for the two variables in this line of
code and view their values as program execution proceeds. To
do this:
1. Press Alt+ X to exit the debugger, and then type Dossales at
the DOS prompt to restart the debugger.
2. Press Alt+P, W (Point Watchpoint).
A dialog box opens on the screen in which you are expected
to enter an expression.
3. Type nTotalAmount and press Retum.
The Watch window opens at the top of the debugger screen
with nTotalArnount displayed as a watchpoint.
4. Press Alt+P, W (Point Watchpoint).
5. Type Sales->Amount and press Retum.
Fl-He lp F2-Zom F3-Repectt F4-User f5-Go f&-WA F7-Here FB-Step F9 BHt FlO Trctce
l r . = = = = = = = = = = = DOSSALES.PRG ==========!U
1: LOCAL cOldSalesnian, nTotal~nt
USE Sales INDEX Salesrep NEW
DO i.tl!LE IEOFO
cOldSalesnian : = Sales->Salesrep
DO i.tl!LE cOldSalesnian = Sales->Salesrep
..
? Sales->Salesrep, Sales-~nt
Sl<IP
f]IDDO
? "Total:", nTotal~nt, "for", cOldSalesnian
fl1DDO
CI.OSE Sa les->
Fl-Help F2-Zom F3-Repeat F1 User FS-Go F&-IJA F7-llere FB-Step F9-BkFt F10-Trace
5-12 CA-Clipper
Starting the Next Debugger Session
Getting Started 5- 13
Starting the Next Debugger Session
5-14 CA-Clipper
Running the Fino I Test
This time, there should beno error messages, and the resulting
program output should show the correct totals for each Salesrep.
Getting Storted 5- 15
Summary
Summary
In this chapter, you learned how to create an executable file that
can be executed using the CA-Clipper DOS-level debugger. You
learned how to use two of the debugger execution modes, Run
and Single Step, to run your application. You learned how to
switch back and forth between the application and the debugger
screen. You learned how to view a database file structure to
determine if a field name had been misused and how to watch
several variables to determine which one was causing a
particular error. Finally, you learned how to initialize a variable
within the debugger to get through the rest of the application
and potentially save an edit, compile, link, and execute cycle.
With these basics in hand, you are now ready to use the
debugger for your own applications. To discover all of the
debugger features that are available to you, refer to the
"CA-Clipper Debugger-CLD.LIB" chapter of the Prograrnming
and Utilities Guide.
5- 16 CA-Clipper
Chapter 6
Creating Data Structures
ln This Chapter
In CA-Clipper, you can create database files using DBU.EXE, an
application written in CA-Clipper designed to provide you with
an interactive database design environment. It allows you to
build database files, add data to the files, browse existing data,
create and attach index files, and construct views within a
completely menu-driven system. The Database Utility (DBU)
also provides many other features and is fully documented in the
"Database Utility-DBU.EXE" chapter of the Programming and
Utilities Guide; this chapter introduces you to some of its basic
features. If you are interested in building data structures to use
with your CA-Clipper programs, you should read this chapter
and further explore DBU on your own.
Executing OBU
To use DBU, type DBU from the DOS prompt followed by
Return. The program loads into memory and leaves you on the
main screen.
6-2 CA-Clipper
Navigation
Navigation
The Menu Bar Once in DBU, you will notice a menu bar across the top of the
screen providing you with several options. Pressing the function
key listed directly above a menu name drops the menu down
allowing you to select from any of its available items.
Unavailable menu items are grayed.
When a menu is open, the Up arrow and Down arrow keys move
the highlight bar within the menu and Retum selects the
currently highlighted item. A shortcut for navigating to a
particular menu item is typing the first letter of its name. The
Right arrow and Left arrow keys move to the next and previous
menus on the menu bar. When no menu is open, you can move
the highlight bar around on the main screen with any of the
directional keys.
The Main Screen Without actually using the menu bar, you can perform many
basic operations on the main screen. For instance, pressing
Retum when the Files area is highlighted allows you to open an
existing database (.dbf) file either by selecting a file name from a
picklist or by typing a file name directly into the dialog box. This
action on the main screen is equivalent to selecting F2 Open
Database from the menu bar. Up to six database files can be
open at one time in DBU. Once a database file is open, the
Indexes and Fields areas become available for your use.
Opening database and index files with Return doses any other
open files that happen to occupy the currently highlighted slot.
lns, on the other hand, allows you to open a file in much the
same way as Return, except that it pushes the other files down
one slot and if necessary, closing the file occupying the last slot
to make room for the new one. Del closes the file in the currently
highlighted slot.
To insert a field, highlight the proper location for the field and
press Ins. A field dialog box opens from which you select the
field to insert from a picklist. This action is equivalent to
selecting F8 Set Fields from the menu bar.
You can combine the actions of inserting a new field and deleting
the current one by highlighting the field you want to delete and
pressing Return. Similar to pressing lns, this action opens the
field dialog box; however, pressing Return causes the field that
you select to overwrite the current field-thus, deleting the
current field and inserting a new one. Using a combination of
these actions, you can construct a field list for the current
database file.
6-4 CA-Clipper
Creating a Database File
In OBU, you define the above field attributes for each field that
you want to include in the database file. This process is known
as creating a database file structure. Later, you can add and
change records in the file according to the field attributes that
you define.
2. Press Return.
A field box opens on the main screen as shown:
F1 F2 FJ F4 FS FG F7 PO
Help Open Create Saue Browse Utility 11oue Set
Pile s
-1
In the field box, you enter the field definitions that make up the
database file structure. For this exercise, the file structure you
will create is as follows:
Lname Character 30
Fname Character 30
Age Numeric 2 o
Notes Memo 10
6-6 CA-Clipper
Creating a Database File
When you are đone, your screen should look something !ike this:
Fl F2 F3 F4 F'5 F6 F7 F8
Help Open Create Saue Browse ut I li ty l'loue Set
Flles
-1
Structure of <neOJ file> Field 1
LNAME Chctracter JO
FNAME Character 30
AGE Numerir. 2 o
NOTES Me mo 10
L ___ _
The database file is created, and its name appears on the main
screen:
F1 FZ F3 F1 F5 F& f7 F8
Help Open Create Saue Browse utl llty Moue Set
Flles
Wiml I
Jndexes
Flelds
UR1E
FtlAME
AGE
l'IJTES
6-8 CA-Clipper
Creating on lndex File
In DBU, you can create and use index files for the active
database file. When an index file is used, the records in the
database file appear in order according to the columns that you
use to define the index key. To create an index file for the active
database that imposes alphabetical order by last and first name,
perform the following steps:
1. Select F3 Create.
The Create Database menu item is highlighted.
2. Select Index.
The Create Index menu item is highlighted.
3. Press Return.
The Create Index dialog box opens on the main screen:
F1 F2 F3 F4 rs F& F7 F8
Help Open Create Saue Browse llt 111ty l'bue Set
Flles
lndexes
In the dialog box, enter the name of the index file and the key
expression as follows:
1. Type SAMPLE after the File prompt and press Return.
The highlight bar moves next to the KEY prompt.
2. Type Lname + Fname and press the Down arrow key.
The OK button is highlighted.
3. Press Return to confirm.
6-1 O CA-Clipper
Creating on lndex File
The index file is created, and its name appears on the main
screen as shown below:
-
I F1 F2 F3 F4 F5 F& F7 F8
Help Open Create Saue Browse utl llty tloue Set
F !le i ndexed
Flles
mmm I
lndexes
Fields
You can have several index files for each database file. To do
this, move the highlight bar just below the current index file in
the Index column with the Down arrow key, and either create a
new file or open an existing one. The controlling index is always
first in the Index list.
Adding Dota
Once the database file structure is defined, you can add data to
the file. Any index files that are currently engaged are
automatically updated to reflect the new records. You add
records using the Browse menu as follows:
1. Select FS Browse.
The Browse Database menu item is highlighted.
2. Press Return.
The Browse window opens on the main screen:
F1 FZ F3 F5
Help Open Create Browse
Files
mDI I
Record <new>
LNAHE FNAHE AGE
6-12 CA-Clipper
Adding Dota
3. Type 92.
The highlight bar automatically moves to the Notes field
because the Age field was completely filled.
For memo fields, you can enter data just as you would for any
other field. As soon as you start typing, a memo editing window
opens. You can also press Return before you start typing to see
any existing information without overwriting it. For example:
Fl FZ F3 Fi F5 F6 F7 FB
Help Open Crea.te Saue Browse ut 111 ty tloue Set
Flles
Blll I
1. Press Return.
An empty window opens as shown above.
2. Type Notes about Joe Smith and press Ctrl+W.
The data you entered is saved in the Notes field.
Getting Started 6- 13
Adding Dota
Piles
!lliili!llm I
You can enter as many records as you like using the Browse
window. When you are done, press Esc to close the window and
return to the main screen.
6-14 CA-Clipper
Editing Dota
Editing Dota
Now that you have added records to the database file, you can
open the Browse window again and see the data you entered:
1. Select FS Browse.
The Browse Database menu item is highlighted.
2. Press Return.
The Browse window opens on the main screen:
P1 P2 P3
Help Open Create
Files
llliilDm I
Feel free to explore the other OBU menu options to see what is
available, and experiment with creating database and index files
ofyourown.
Gettina Started 6- 15
Leaving DBU
Leaving OBU
To exit OBU when you are finished:
1. Press Esc.
You are prompted with the following message:
Exit to DOS? (Y /N).
2. Type Y and press Enter.
You are returned to the DOS prompt.
All files that you created and any data that you added or
changed is automatically saved.
Summary
In this chapter, you have been introduced to some of the most
important features of OBU. You learned how to navigate within
the OBU menu system, to create a database file and an index file,
and to add and edit data. OBU is intended as a utility to design
data structures that will ultimately be used in your CA-Clipper
application programs. For more information on OBU, refer to
the "Oatabase Utility-OBU.EXE" chapter of the Programming
and Utilities Guide.
6- 16 CA-Clipper
Chapter 7
DOS Online Documentation:
The Guide To CA-Clipper
ln This Chapter
This chapter introduces you to The Guide To CA-Clipper, online
documentation at the DOS level provided as part of the
CA-Clipper package. It acquaints you with the concept of The
Guide To CA-Clipper and teaches you the rudiments of loading,
using, and leaving the Norton Instant Access Engine.
The Instant Access Engine lets you display information from The
Guide To CA-Clipper databases at the touch of a shortcut key.
Other databases (e.g., C, Assembler, and third-party CA-Clipper
libraries) designed for use with the Instant Access Engine are
available from third-party vendors.
7-2 CA-Clipper
Loading The Guide To CA-Clippe1
After you load the Instant Access Engine into memory, The Guide
To CA-Clipper help databases are available to you even though
no information appears on your screen. To get help at any time
without having to quit what you are doing (perhaps operating
from the DOS prompt or using your word processor to edit a
program), simply press Shift+Fl.
Note: If you are using DOS 5.0 or higher, you must press Fl or
Esc immediately after Shift+Fl to activate the lnstant Access
Engine. On some computers, using Esc here will cause the
computer to hang up momentarily after you leave the Norton
Guide. Using Fl avoids this. If you place the statement
SWITCHES=/k in your CONFIG.SYS file, you will not have to
press Fl or Esc after Shift+Fl.
Navigation
When the Instant Access Engine is active, there is a menu bar
across the top of the screen providing you with several options.
Use the Left arrow and Right arrow keys tomove the highlight
to a new menu option. If the menu bar option has an associated
menu, the menu drops down and the first item is highlighted. If
there are no pull-down menus open, you can select a menu bar
option by typing the first letter of the option.
ABSO
..
Return the abliolute value oF a nut1eric expres:sion
ACHOICEO Execute ili pop-up Menu
ACLON!O J>11plloah a ne„hđ or ""ll1đlt1enslonal •rr•'l
ACOPYO Cap~ e lertents rro"' one ilrril~ to anot.her
ADELO Delete an arril!:J elenenl
Al>IRO• Fili • serles of arra'l" ulth đlrector'l lnfort1•tlon
AE~ALO Execule a code hlock rcir each elet1Emt in an iilrra~
AFIELDSO• Fi 11 ilrra~:s 1.1i t.h the ::slrm::t.ure af' the curr-ent dillaba:se file .j!.i.!
AFILLO Fiii •n •rro'j ~lth • speclfled. value
Al~SO Insert NIL eliet'!enl int.o an arra!:J
ili ~·:!
ALERTO
ALIASO
Displil~ ii :siMple Modal dic1log ba>C
Relur-n a s.pE!'clf:lE!d uork area allas
l:ii;·;:
ALLTHIMO ReHove leadtng a.nd trat ltng spaoes fr-ot1 a chariac:Ler string ,-.11! . . i,
•..
·.i
This menu option is the only one that does not have an
associated pull-down menu. When Expand is highlighted, the
Up arrow and Down arrow keys allow you to navigate through
the alphabetical entries. Return allows you to expand the
highlighted entry.
7-4 CA-Clipper
Finding lnformation
Finding lnformation
Entries on the main part of the screen are items in the current
category. The default category is Functions, but you can select
other categories from the Language menu. Commands and
Operators are examples of other categories that are available.
For example:
1. Select L Language.
The Language menu is displayed.
2. Press O to select the Language Operators menu item.
The Operators short entry list is displayed in place of the
Functions on the main screen.
'Niflf-
"'c"o1cEo Execute 11 pcip-up l"lenu
a nUl'li!rlo expres:slon
ACL~EO Duplicat11 a ne1>t.eđ o:r 11ul ti-diMensional arra!:t
ACOP~O Ciop~ eh!11ents frof't one arrCll'.!11 to anathel' :';i
ADELO Delete an ar:ralj eleHent
ADIRO• Fill a se:ries of 11rrays 1-1ilh di:rec:tl):r~ inforl'tation
AEUALO Execute a oode blook for eaio.h eler1ent in an array i,i!
AFIELDSO~ Fill arr111ys with lhe str-uc:Lul"'e of the curr-enl databas;e file
AFILLO Fill an 111rray 1.lith ii spl!!!c:ified Villue
AIHSO Insert a l'tlL ele11ent into an a:rr-a!:j
ALERTO Dlspla~ ii shtplE! l'todal dialo9 box
ALIASO R11lul"n • specified 1.101"'.k iiH"Ba aliAli 1·:;
ALLTRl~O
ALTDO
ReHave l eadt 'f\9' ar1d t:t'af li n91 spaces frooH a ch111racler :st:r l ng
lnvoke The Cllpper llebug9er
Ji:.;·,•:.
;:i
ARRA~C) C:r11~t.e an uninitialized ilrril~ of specifil!ld len9t.h i'i:
ASCC) Convert ii cha.ractet" ta t ts ASCII -.ialue li i
ASCAHO Sc1.n •n it.l''l"&Y for • V&lua ()1' u.nti l ili hlock returns truli!' c r.) j;i:
ASIZ:EO Graw or shrink •n al':r•!:of !m
ASORTO Sort. an ilt"ra.y
ATO Return the posltlon of a suhstrln9 ulthln • chuachr strlns
SUBSTllO
E~lract a Sllbstring Frori iii character strin9
S~ntaK
~
(nCount} is the nuttber of charaicters to e:i<tract. If ottitled, the
subslring beglns at <nShrt> and conlhmes to lh" "nd ar lh" slring.
7-6 CA-Clipper
Finding lnformation
When you expand an entry as you have just done, the rnenu bar
becomes ternporarily disabled, and its function is taken over by
the See Also line which gives you a cross-reference to related
entries.
As with the menu bar, you use the Left arrow and Right arrow
keys (or the first letter shortcut) to navigate the See Also list.
Pressing Retum shows you the expanded text for the currently
highlighted See Also reference. For instance, to view the
expanded text for AT(), the first See Also itern for SUBSTR():
1. Press Retum.
The AT() entry is expanded as shown below:
CA-tllpper 5.3 » Ti\• Gulde To CA-Cllpper " Language „ Functions • ...
Se• al so: llilillDI STRTR~MO SUBsrno
----~
Aro
Relurn the pos:ilion of ili suhslring uithin a characler string
Relurns
Descrlptlon
2. Press Esc.
3. Press the Down arrow key until you highlight the Utilities
database, and then press Return.
The Utilities database is Ioaded and its help text replaces that of
the current database on the main screen.
At this point, you have seen ali of the main features of The Guide
To CA-Clipper. You may want to take some time now and
explore the menu bar to see what else is available.
--··---··-----------------
7-8 CA-Clipper
Leaving The Guide To CA-Clippe
Summary
In this chapter, you have been introduced to The Guide To
CA-Clipper with enough information to allow you to explore it on
your own. For more detailed information on the Instant Access
Engine and The Guide To CA-Clipper databases, refer to "Online
Documentation-NG.EXE" chapter in the Programming and
Utilities Guide.
Manual Organization
The CA-Clipper documentation set is divided into seven guides.
Each guide is designed to target a specific aspect of the system.
• Getting Started
This is the guide you are reading now. It is designed to give
you all the information you will need to install CA-Clipper
on your computer as well as introduce you to some of its
features and benefits.
• Reference Guide, Volumes 1 and 2
This is the complete reference to the CA-Clipper language.
The language reference is organized alphabetically into a
single chapter containing all language items, without regard
to categorization, to make it easier for you to locate the
information you need. With this organization, you need
only the name of an item to find the information you want.
Each item in the CA-Clipper language falls into one of the
following categories: class, command, directive, function,
operator, or statement. The category name follows the item
name in the language reference heading.
Getting Storted 8- l
Manual Organization
8-2 CA-Clipper
Manual Organization
Development Tools
CA-Clipper has a number of tools you will use to create and
develop your programs. If you have reviewed all of the chapters
in this guide and installed the CA-Clipper development system,
you should already be familiar with most of these programs. If
not, the following descriptions will give you an introduction as
well as point to where the program is installed and where to find
more information in the documentation.
• CA-Clipper Compiler-CLIPPER.EXE
The CA-Clipper compiler is a standard command line driven
compiler that supports a number of command line options
and environment variables. Invoking it without specifying a
source file lists all the available options.
Default lnstallation: Executable file in \CLIP53\BIN.
8-4 CA-Clipper
Development Tool:
• Program Editor-PE.EXE
PE.EXE isa simple text editor written in CA-Clipper that you
can use to create small program (.prg) files.
Default lnstallation: Source files in
\CLIP53\SOURCE\PE; executable file in \CLIP53\BIN.
Documentation: Complete documentation: Programming
and Utilities Guide; Command line documentation: The
Guide To CA-Clipper and Quick Reference Guide.
• Database Utility-DBU.EXE
DBU.EXE isa database creation and modeling utility written
in CA-Clipper. lt can be used to create database and index
files, model relations between database files, and edit data.
Default lnstallation: Source files in
\CLIP53\SOURCE\DBU; executable file in
\CLIP53\BIN.
Documentation: Complete documentation: Programming
and Utilities Guide; Command line documentation: The
Guide To CA-Clipper and Quick Reference Guide; Tutorial:
Getting Started guide, "Creating Data Structures"
chapter.
• Report and Label Utility-RL.EXE
RL.EXE isa report and label creation utility written in
CA-Clipper. lt can be used to create report form (.frm) and
label (.lbl) definitions that can be executed by the REPORT
and LABEL FORM commands, respectively.
Default lnstallation: Source files in
\CLIP53\SOURCE\RL; executable file in \CLIP53\BIN.
Documentation: Complete documentation: Programming
and Utilities Guide; Command line documentation: The
Guide To CA-Clipper and Quick Reference Guide; Reference:
Reference Guide, LABEL FORM and REPORT FORM
entries.
8-6 CA-Clipper
Development Tools