Salesforce

COMHandleSet (Magic xpa 3.x)

« Go Back

Information

 
Created ByKnowledge Migration User
Approval Process StatusPublished
Objective
Description

COMHandleSet (Magic xpa 3.x)

Lets you refer to an object, previously loaded from a COM object field, using a handle number returned by the COMHandleGet function.

Syntax:

COMHandleSet(variable reference, handle)

Parameters:

variable reference – The value representing a variable index in the Variable list.

handle – A numeric value of a handle that was retrieved using the COMHandleGet function.

Returns:

0 when the function is successful. A negative number is returned when the function fails.

The negative numbers that the function can return are:

-1 – The attribute is not an OLE variable.

-2 – The Instantiation property is set to Automatic.

-3 – The object is not loaded by the defined variable.

-4 – The handle provided by the variable is not a valid handle.

-5 – The object was already instantiated.

-6 – The object could not be updated.

Note:

Handling objects using the COMHandleGet and COMHandleSet functions should be done with caution. Accidentally assigning wrong handles to wrong objects may result in unexpected behavior.

Reference
Attachment 
Attachment