Skip to main content

$ZF(-6) (ObjectScript)

Executes a DLL function indexed using $ZF(-4). This function is a component of the Callout SDK.

Synopsis

$ZF(-6,dll_index,func_id,args)

Arguments

Argument Description
dll_index A user-specified index to a DLL filename in the DLL index tables, from $ZF(-4).
func_id Optional — The ID value of the function within the DLL as supplied by $ZF(-4). If omitted, call verifies the validity of DLL_index, loads the image, and returns the image location.
args Optional — The argument(s) to pass to the function, if any, specified as a comma-separated list.

Description

$ZF(-6) provides a fast Dynamic Link Library (DLL) function interface using a user-defined index for a DLL filename. You establish this user-defined index in $ZF(-4) by assigning an integer (dll_index) to uniquely associate with a dll_name. You can place this entry in either a process DLL index table, or a system DLL index table.

Both $ZF(-5) and $ZF(-6) can be used to execute a function from a DLL. which has been located by $ZF(-4).

For a detailed description of how to use $ZF(-6), refer to Using $ZF(-6) to Access Libraries by User Index.

Loading a DLL Dependent on Another DLL

On Windows, some system DLLs that are installed in the bin directory are dependent on other DLLs in the bin directory. Windows search rules do not find the dependencies in the bin directory unless bin is added to the process's PATH. However, if one of these DLLs is invoked using $ZF(-4) or $ZF(-6), InterSystems IRIS first searches the directory from which the DLL is being loaded for dependent DLLs; if the dependent DLLs are not found there, the default search PATH is used. InterSystems IRIS does this by using a Windows load operation that temporarily adds the originating directory to the PATH while the DLL is loaded. This temporary PATH addition is used when the DLL is loaded by $ZF(-4) or $ZF(-6). This temporary PATH addition is not used when the DLL is loaded by $ZF(-3).

If a DLL dependency cannot be resolved, InterSystems IRIS issues a <DYNAMIC LIBRARY LOAD> error.

See Also

FeedbackOpens in a new tab