GETEXENAME

Purpose:

Returns the path and name of the executable.

Syntax:

GETEXENAME(type)

type

-

Optional. An integer, the target path type.

0:

return full path and executable name (default)

1:

return the path component to the executable

2:

return the unique ActiveX automation server name for the running instance

3:

return the process id or PID for the running instance as a string

Returns:

A string.

Example:

getexename

 

Returns the full path to the executable. The string is similar to:

 

\program files\dadisp\dadispnt.exe

Example:

getexename(2)

 

Returns the unique ActiveX automation server name for the running instance. The string is similar to:

 

DADiSP Automation Server:1748

Remarks:

GETEXENAME returns the full pathname of the executable program.

 

Each running instance of DADiSP registers a unique name so that an ActiveX client can connect to a specific instance. The name is of the form:

 

DADiSP Automation Server:pid

 

Where pid is an integer, the process identification number. For example:

 

DADiSP Automation Server:1748

 

Identifies the running instance of the automation server with process id 1748.

 

A simple procedure to connect one running instance of DADiSP with another:

 

In DADiSP 1:

 

copydata(getexename(2));

 

In DADiSP 2:

 

dadisp1 = getobject(pastedata(3));

 

Now DADiSP 2 can access DADiSP 1 via the dadisp1 object.

See Also:

CREATEOBJECT

GETCOMPUTER

GETHOME

GETLABNAME

GETLABPATH

GETOBJECT

GETWORKSHEETNAME

PASTEDATA