Application Integration Guide > CallAPI > CallAPI and your own program > Visual Basic

 Visual Basic

The CallAPI can be used to process scripts in the AE system from your own VB programs.

This function is found in the COM object AE.Call3 which must be registered.

Example: regsvr32 c:\AUTOMIC\callapi\windows\bin\ucxbwi3c.dll

The delivery directory contains a sample program that provides a detailed description of how a script activation can be implemented.

General

  1. Scripts are always activated with the following steps:
    1. Log on to the AE system.
    2. Transfer the script to the AE system.
    3. Log off from the AE system.

You can log on to several AE systems at the same time and process various scripts. In this case, a Dialog license is used for each connection.

Methods

In your program, you can use the functions listed below. They supply return code 0 if the action was successful, or a message number if an error occurred.

Description

Method

Logging on to the AE system

Logonclient, user, [departmentDepartment name to which the Automation Engine user belongs., [passwordA secret combination of characters for a Automation Engine user.]]

Specifying INI file

SetIniFile path and name of INI file

Logging on using INI-file data

LogonAsDefault

Activating a script

ActivateScript script

Logging off the AE system

Logoff

Attributes

Information about script execution is automatically stored in variables.

Data type

Variable

Description

Long

lRunNr

RunID of the script

Long

lRetCode

Return code of script execution

String

cRetText

Variable message part which explains the return code value

 

See also:

About the CallAPI