Progress
External Program
Interfaces
Preface
Purpose
Many operating systems and user interfaces provide tools that allow one application to exchange data or use services provided by another application (external program). Progress allows you to use some of these tools as external program interfaces (EPIs) from within a Progress application. This manual describes the EPIs that Progress supports, and explains how to use them from the 4GL to integrate your Progress application with other applications in your operating environment.
Audience
This manual is intended for any Progress programmer who is writing applications that require the use of external programming interfaces. In general, this programmer has a working knowledge of both the EPIs and the operating systems in which the EPIs run.
Organization Of This Manual
Describes the EPIs supported by Progress, what they can provide for your applications, and the requirements for using them.
"Host Language Call Interface"
Describes how to use the Host Language Call Interface, how to build an HLC executable, and how to use the Progress HLC tank demo application.
Describes how to use the CLIPBOARD handle to read and write data to the system clipboard, and how to provide user interactions between the system clipboard and your Progress application.
Describes how to use named pipes to provide interprocess communication (IPC) between your Progress application and another application running on either the UNIX operating system or Windows NT. It emphasizes techniques that enable any Progress application to be a data server for the external application.
"Shared Library and DLL Support"
Describes how to call UNIX shared library functions and Windows dynamic link library (DLL) functions from a Progress application. This includes how to declare shared library functions as internal procedures and how to pass Progress data items as shared library parameters.
"Windows Dynamic Data Exchange"
Describes how to use dynamic data exchange (DDE) in Windows to send and receive data between your Progress application running as a DDE client and another application running as a DDE server.
"Using COM Objects In the 4GL"
Describes Progress support for COM objects, including information common to both ActiveX Automation objects and ActiveX Controls.
Describes Progress support for ActiveX Automation and how to implement a Progress application as an ActiveX Automation Controller from the 4GL.
Describes Progress support for ActiveX controls in the 4GL, including how to convert an earlier application using VBX controls to the same application using ActiveX controls.
Describes Progress support for the use of sockets in the 4GL, including connecting to and disconnecting from a port using sockets and receiving and transmitting data.
Describes Progress support for XML in the 4GL, including the receipt and processing of XML documents and the creation and transmission of XML documents.
Describes Progress support for SAX and provides a SAX API reference.
"Accessing SonicMQ Messaging From the Progress 4GL"
Introduces the Progress SonicMQ Adapter
Tells you how to use the Progress SonicMQ Adapter
"HLC Library Function Reference"
Provides a functional grouping and alphabetical reference of the HLC library functions.
"COM Object Data Type Mapping"
Describes the automatic conversion support between COM data types and Progress data types for COM object properties, methods, and events.
Provides an API reference for the Progress SonicMQ Adapter
Typographical Conventions
This manual uses the following typographical conventions:
The following typographical conventions are used to represent keystrokes:
- Small capitals are used for Progress key functions and generic keyboard keys.
END-ERROR, GET, GO
ALT, CTRL, SPACEBAR, TAB- When you have to press a combination of keys, they are joined by a dash. You press and hold down the first key, then press the second key.
CTRL-X
- When you have to press and release one key, then press another key, the key names are separated with a space.
ESCAPE H
ESCAPE CURSOR-LEFTSyntax Notation
The syntax for each component follows a set of conventions:
- Uppercase words are keywords. Although they are always shown in uppercase, you can use either uppercase or lowercase when using them in a procedure.
In this example, ACCUM is a keyword:
- Italics identify options or arguments that you must supply. These options can be defined as part of the syntax or in a separate syntax identified by the name in italics. In the ACCUM function above, the aggregate and expression options are defined with the syntax for the ACCUM function in the Progress Language Reference .
- You must end all statements (except for DO, FOR, FUNCTION, PROCEDURE, and REPEAT) with a period. DO, FOR, FUNCTION, PROCEDURE, and REPEAT statements can end with either a period or a colon, as in this example:
- Square brackets ([ ]) around an item indicate that the item, or a choice of one of the enclosed items, is optional.
In this example, STREAM stream, UNLESS-HIDDEN, and NO-ERROR are optional:
In some instances, square brackets are not a syntax notation, but part of the language.
For example, this syntax for the INITIAL option uses brackets to bound an initial value list for an array variable definition. In these cases, normal text brackets ( [ ] ) are used:
NOTE: The ellipsis (...) indicates repetition, as shown in a following description.
- Braces ({ }) around an item indicate that the item, or a choice of one of the enclosed items, is required.
In this example, you must specify the items BY and expression and can optionally specify the item DESCENDING, in that order:
In some cases, braces are not a syntax notation, but part of the language.
For example, a called external procedure must use braces when referencing arguments passed by a calling procedure. In these cases, normal text braces ( { } ) are used:
- A vertical bar (|) indicates a choice.
In this example, EACH, FIRST, and LAST are optional, but you can only choose one:
In this example, you must select one of logical-name or alias:
- Ellipses (...) indicate that you can choose one or more of the preceding items. If a group of items is enclosed in braces and followed by ellipses, you must choose one or more of those items. If a group of items is enclosed in brackets and followed by ellipses, you can optionally choose one or more of those items.
In this example, you must include two expressions, but you can optionally include more. Note that each subsequent expression must be preceded by a comma:
In this example, you must specify MESSAGE, then at least one of expression or SKIP, but any additional number of expression or SKIP is allowed:
In this example, you must specify {include-file, then optionally any number of argument or &argument-name = "argument-value", and then terminate with }:
- In some examples, the syntax is too long to place in one horizontal row. In such cases, optional items appear individually bracketed in multiple rows in order, left-to-right and top-to-bottom. This order generally applies, unless otherwise specified. Required items also appear on multiple rows in the required order, left-to-right and top-to-bottom. In cases where grouping and order might otherwise be ambiguous, braced (required) or bracketed (optional) groups clarify the groupings.
In this example, WITH is followed by several optional items:
In this example, ASSIGN requires one of two choices: either one or more of field, or one of record. Other options available with either field or record are grouped with braces and brackets. The open and close braces indicate the required order of options:
Example Procedures
This manual provides numerous example procedures that illustrate syntax and concepts. Examples use the following conventions:
- They appear in boxes with borders.
- If they are available online, the name of the procedure appears above the left corner of the box and starts with a prefix associated with the manual that references it, as follows:
e-
— Progress External Program Interfaces , for example,e-ddeex1.p
lt-
— Progress Language Tutorials, for example,lt-05-s3.p
p-
— Progress Programming Handbook , for example,p-br01.p
r-
— Progress Language Reference , for example,r-dynbut.p
If the name does not start with a listed prefix, the procedure is not available online.
- If they are not available online, they compile as shown, but might not execute for lack of completeness.
Accessing Files In Procedure Libraries
Documentation examples are stored in procedure libraries,
prodoc.pl
andprohelp.pl
, in thesrc
directory where Progress is installed.You must first create all subdirectories required by a library before attempting to extract files from the library. You can see what directories and subdirectories a library needs by using the PROLIB -list command to view the contents of the library. See the Progress Client Deployment Guide for more details on the PROLIB utility.
Creating a Listing Of the Procedure Libraries
Creating a listing of the source files from a procedure library involves running PROENV to set up your Progress environment, and running PROLIB.
- From the Control Panel or the Progress Program Group, double-click the Proenv icon.
- The Proenv Window appears, with the proenv prompt.
Running Proenv sets the DLC environment variable to the directory where you installed Progress (by default,
C:\Program Files\Progress
). Proenv also adds the DLC environment variable to your PATH environment variable and adds the bin directory (PATH=%DLC%;%DLC%\bin;%PATH%).
- Enter the following command at the proenv prompt to create the text file
prodoc.txt
which contains the file listing for the prodoc.pl library.
Extracting Source Files From Procedure Libraries On Windows Platforms
Extracting source files from a procedure library involves running PROENV to set up your Progress environment, creating the directory structure for the files you want to extract, and running PROLIB.
- From the Control Panel or the Progress Program Group, double-click the Proenv icon.
- The Proenv Window appears, with the proenv prompt.
Running Proenv sets the DLC environment variable to the directory where you installed Progress (by default,
C:\Program Files\Progress
). Proenv also adds the DLC environment variable to your PATH environment variable and adds the bin directory (PATH=%DLC%;%DLC%\bin;%PATH%)
.- Enter the following command at the proenv prompt to create the
prodoc
directory in your Progress working directory (by default,C:\Progress\Wrk
):
- Create the
langref
directory underprodoc
:
- To extract all examples in a procedure library directory, run the PROLIB utility. Note that you must use double quotes because “Program Files” contains an embedded space:
PROLIB extracts all examples into
prodoc\langref
.To extract one example, run PROLIB and specify the file that you want to extract as it is stored in the procedure library:
PROLIB extracts
r-syshlp.p
intoprodoc\langref
.Extracting Source Files From Procedure Libraries On UNIX Platforms
To extract
p-wrk1.p
fromprodoc.pl
, a procedure library, follow these steps at the UNIX system prompt:
- Run the PROENV utility:
Running proenv sets the DLC environment variable to the directory where you installed Progress (by default,
/usr/dlc
). The proenv utility also adds the bin directory under the DLC environment variable to your PATH environment variable (PATH=$DLC/bin:$PATH).
- At the proenv prompt, create the
prodoc
directory in your Progress working directory:
- Create the
proghand
directory underprodoc
:
- To extract all examples in a procedure library directory, run the PROLIB utility:
PROLIB extracts all examples into
prodoc/proghand
.To extract one example, run PROLIB and specify the file that you want to extract as it is stored in the procedure library:
PROLIB extracts
p-wrk-1.p
intoprodoc/proghand
.Progress Messages
Progress displays several types of messages to inform you of routine and unusual occurrences:
- Execution messages inform you of errors encountered while Progress is running a procedure (for example, if Progress cannot find a record with a specified index field value).
- Compile messages inform you of errors found while Progress is reading and analyzing a procedure prior to running it (for example, if a procedure references a table name that is not defined in the database).
- Startup messages inform you of unusual conditions detected while Progress is getting ready to execute (for example, if you entered an invalid startup parameter).
After displaying a message, Progress proceeds in one of several ways:
- Continues execution, subject to the error-processing actions that you specify, or that are assumed, as part of the procedure. This is the most common action taken following execution messages.
- Returns to the Progress Procedure Editor so that you can correct an error in a procedure. This is the usual action taken following compiler messages.
- Halts processing of a procedure and returns immediately to the Procedure Editor. This does not happen often.
- Terminates the current session.
Progress messages end with a message number in parentheses. In this example, the message number is 200:
On the Windows platform, use Progress online help to get more information about Progress messages. Many Progress tools include the following Help menu options to provide information about messages:
- Choose Help
Recent Messages to display detailed descriptions of the most recent Progress message and all other messages returned in the current session.
- Choose Help
Messages, then enter the message number to display a description of any Progress message. (If you encounter an error that terminates Progress, make a note of the message number before restarting.)
- In the Procedure Editor, press the HELP key (F2 or CTRL-W).
On the UNIX platform, use the Progress PRO command to start a single-user mode character Progress client session and view a brief description of a message by providing its number. Follow these steps:
Other Useful Documentation
This section lists Progress Software Corporation documentation that you might find useful. Unless otherwise specified, these manuals support both Windows and Character platforms and are provided in electronic documentation format on CD-ROM.
Getting Started
Progress Electronic Documentation Installation and Configuration Guide (Hard copy only)
A booklet that describes how to install the Progress EDOC viewer and collection on UNIX and Windows.
Progress Installation and Configuration Guide Version 9 for UNIX
A manual that describes how to install and set up Progress Version 9.1 for the UNIX operating system.
Progress Installation and Configuration Guide Version 9 for Windows
A manual that describes how to install and set up Progress Version 9.1 for all supported Windows and Citrix MetaFrame operating systems.
Progress Version 9 Product Update Bulletin
A bulletin that provides a list of new and changed features by release, a list and description of changes to documentation by release, and critical information about product changes that might require changes to existing code and configurations.
This bulletin also provides information about where to go for detailed information about the new and changed features and documentation.
Progress Application Development Environment — Getting Started (Windows only)
A practical guide to graphical application development within the Progress Application Development Environment (ADE). This guide includes an overview of the ADE and its tools, an overview of Progress SmartObject technology, and tutorials and exercises that help you better understand SmartObject technology and how to use the ADE to develop applications.
Progress Language Tutorial for Windows and Progress Language Tutorial for Character
Platform-specific tutorials designed for new Progress users. The tutorials use a step-by-step approach to explore the Progress application development environment using the 4GL.
Progress Master Glossary for Windows and Progress Master Glossary for Character (EDOC only)
Platform-specific master glossaries for the Progress documentation set. These books are in electronic format only.
Progress Master Index and Glossary for Windows and Progress Master Index and Glossary for Character (Hard copy only)
Platform-specific master indexes and glossaries for the Progress hard-copy documentation set.
Progress Startup Command and Parameter Reference
A reference manual that describes the Progress startup and shutdown commands that you use at the command line, and the startup parameters that you use for Progress processes. This guide also provides information about parameter usage and parameter files.
Welcome to Progress (Hard copy only)
A booklet that explains how Progress software and media are packaged. An icon-based map groups the documentation by functionality, providing an overall view of the documentation set. Welcome to Progress also provides descriptions of the various services Progress Software Corporation offers.
Development Tools
A guide to using the Application Development Model, Version 2 (ADM 2) application architecture to develop Progress applications. It includes instructions for building and using Progress SmartObjects.
A reference for the Application Development Model, Version 2 (ADM 2) application. It includes descriptions of ADM 2 functions and procedures.
Progress AppBuilder Developer’s Guide (Windows only)
A programmer’s guide to using the Progress AppBuilder visual layout editor. AppBuilder is a Rapid Application Development (RAD) tool that can significantly reduce the time and effort required to create Progress applications.
Progress Basic Database Tools (Character only; information for Windows is in online help)
A guide for the Progress Database Administration tools, such as the Data Dictionary.
Progress Basic Development Tools (Character only; information for Windows is in online help)
A guide for the Progress development toolset, including the Progress Procedure Editor and the Application Compiler.
A guide for the Progress Application Debugger. The Debugger helps you trace and correct programming errors by allowing you to monitor and modify procedure execution as it happens.
Progress Help Development Guide (Windows only)
A guide that describes how to develop and integrate an online help system for a Progress application.
Progress Translation Manager Guide (Windows only)
A guide that describes how to use the Progress Translation Manager tool to manage the entire process of translating the text phrases in Progress applications.
Progress Visual Translator Guide (Windows only)
A guide that describes how to use the Progress Visual Translator tool to translate text phrases from procedures into one or more spoken languages.
Reporting Tools
Progress Report Builder Deployment Guide (Windows only)
An administration and development guide for generating Report Builder reports using the Progress Report Engine.
Progress Report Builder Tutorial (Windows only)
A tutorial that provides step-by-step instructions for creating eight sample Report Builder reports.
Progress Report Builder User’s Guide (Windows only)
A guide for generating reports with the Progress Report Builder.
Progress Results Administration and Development Guide (Windows only)
A guide for system administrators that describes how to set up and maintain the Results product in a graphical environment. This guide also describes how to program, customize, and package Results with your own products. In addition, it describes how to convert character-based Results applications to graphical Results applications.
Progress Results User’s Guide for Windows and Progress Results User’s Guide for UNIX
Platform-specific guides for users with little or no programming experience that explain how to query, report, and update information with Results. Each guide also helps advanced users and application developers customize and integrate Results into their own applications.
4GL
Building Distributed Applications Using the Progress AppServer
A guide that provides comprehensive information about building and implementing distributed applications using the Progress AppServer. Topics include basic product information and terminology, design options and issues, setup and maintenance considerations, 4GL programming details, and remote debugging.
Progress Internationalization Guide
A guide to developing Progress applications for markets worldwide. The guide covers both internationalization—writing an application so that it adapts readily to different locales (languages, cultures, or regions)—and localization—adapting an application to different locales.
A three-volume reference set that contains extensive descriptions and examples for each statement, phrase, function, operator, widget, attribute, method, and event in the Progress language.
A manual that describes how to use the new WebClient, AppServer Internet Adapter, SmartObjects, and SonicMQ Adapter to create applications tailored for Internet, intranet, and extranet environments.
A two-volume handbook that details advanced Progress programming techniques.
Database
Progress Database Design Guide
A guide that uses a sample database and the Progress Data Dictionary to illustrate the fundamental principles of relational database design. Topics include relationships, normalization, indexing, and database triggers.
Progress Database Administration Guide and Reference
This guide describes Progress database administration concepts and procedures. The procedures allow you to create and maintain your Progress databases and manage their performance.
DataServers
Progress DataServer Guides
These guides describe how to use the DataServers to access non-Progress databases. They provide instructions for building the DataServer modules, a discussion of programming considerations, and a tutorial.
Each DataServer has its own guide as follows:
MERANT ODBC Branded Driver Reference
The Enterprise DataServer for ODBC includes MERANT ODBC drivers for all the supported data sources. For configuration information, see the MERANT documentation, which is available as a PDF file in installation-path
\odbc
. To read this file you must have the Adobe Acrobat Reader Version installed on your system. If you do not have the Adobe Acrobat Reader, you can download it from the Adobe Web site at:http://www.adobe.com/products/acrobat/readstep.html.
SQL-89/Open Access
Progress Embedded SQL-89 Guide and Reference
A guide to Progress Embedded SQL-89 for C, including step-by-step instructions on building ESQL-89 applications and reference information on all Embedded SQL-89 Preprocessor statements and supporting function calls. This guide also describes the relationship between ESQL-89 and the ANSI standards upon which it is based.
Progress Open Client Developer’s Guide
A guide that describes how to write, build, and deploy Java and ActiveX applications, and Java applets that run as clients of the Progress AppServer. This guide includes information about how to expose the AppServer as a set of Java classes or as an ActiveX server, and how to choose an Open Client distribution package for run time.
Progress SQL-89 Guide and Reference
A user guide and reference for programmers who use interactive Progress/SQL-89. It includes information on all supported SQL-89 statements, SQL-89 Data Manipulation Language components, SQL-89 Data Definition Language components, and supported Progress functions.
SQL-92
Progress Embedded SQL-92 Guide and Reference
A guide to Progress Embedded SQL-92 for C, including step-by-step instructions for building ESQL-92 applications and reference information about all Embedded SQL-92 Preprocessor statements and supporting function calls. This guide also describes the relationship between ESQL-92 and the ANSI standards upon which it is based.
A guide to the Java Database Connectivity (JDBC) interface and the Progress SQL-92 JDBC driver. It describes how to set up and use the driver and details the driver’s support for the JDBC interface.
A guide to the ODBC interface and the Progress SQL-92 ODBC driver. It describes how to set up and use the driver and details the driver’s support for the ODBC interface.
Progress SQL-92 Guide and Reference
A user guide and reference for programmers who use Progress SQL-92. It includes information on all supported SQL-92 statements, SQL-92 Data Manipulation Language components, SQL-92 Data Definition Language components, and Progress functions. The guide describes how to use the Progress SQL-92 Java classes and how to create and use Java stored procedures and triggers.
Deployment
Progress Client Deployment Guide
A guide that describes the client deployment process and application administration concepts and procedures.
A guide to using the Developer’s Toolkit. This guide describes the advantages and disadvantages of different strategies for deploying Progress applications and explains how you can use the Toolkit to deploy applications with your selected strategy.
A guide that explains how to use the Progress toolset to build applications that are portable across all supported operating systems, user interfaces, and databases, following the Progress programming model.
WebSpeed
Provides an introduction to the WebSpeed Workshop tools for creating Web applications. It introduces you to all the components of the WebSpeed Workshop and takes you through the process of creating your own Intranet application.
WebSpeed Installation and Configuration Guide
Provides instructions for installing WebSpeed on Windows and UNIX systems. It also discusses designing WebSpeed environments, configuring WebSpeed Brokers, WebSpeed Agents, and the NameServer, and connecting to a variety of data sources.
Provides a complete overview of WebSpeed and the guidance necessary to develop and deploy WebSpeed applications on the Web.
WebSpeed Product Update Bulletin
A booklet that provides a brief description of each new feature of the release. The booklet also explains where to find more detailed information in the documentation set about each new feature.
Welcome to WebSpeed (Hard copy only)
A booklet that explains how WebSpeed software and media are packaged. Welcome to WebSpeed! also provides descriptions of the various services Progress Software Corporation offers.
Reference
Pocket Progress (Hard copy only)
A reference that lets you quickly look up information about the Progress language or programming environment.
Pocket WebSpeed (Hard copy only)
A reference that lets you quickly look up information about the SpeedScript language or the WebSpeed programming environment.
Copyright © 2004 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |