Try OpenEdge Now
skip to main content
Programming Interfaces
External Program Interfaces : Shared Library and DLL Support : Accessing a shared library entry point : Declaring a shared library for static access : Options for static access to a shared library routine
 
Options for static access to a shared library routine
In the syntax, the proc-name value is the name of your shared library routine. The EXTERNAL option indicates that the procedure being declared is an internal procedure implemented by an external shared library routine. The dllname value is the name of the shared library file that contains the routine.
If you specify the PERSISTENT option, the entire shared library remains loaded until ABL exits, or until you explicitly unload the shared library by using the ABL RELEASE EXTERNAL statement.
Each parameter-definition value consists of a DEFINE PARAMETER statement. This is the syntax you must use for the DEFINE PARAMETER statement in a DLL routine declaration:

Syntax

DEFINE { INPUT | OUTPUT | INPUT-OUTPUT | RETURN }
  PARAMETER parameter
  {{ LIKE field}|{ AS [ HANDLE TO ]data-type}}
Each DEFINE PARAMETER statement specifies an INPUT, OUTPUT, or INPUT-OUTPUT parameter in the order it appears in the calling sequence of your shared library routine. You can also (optionally) define one RETURN parameter that provides the function return value of your shared library routine.
The parameter name (parameter) serves only as a place holder, and can take any unique identifier value. The ASdate-type and LIKEfield options require a special set of data types for shared library parameter definitions.