Share via


ObjectFrame.LpOleObject Property (Access)

You can use the LpOLEObject property in Visual Basic to determine the memory address of an OLE object. The LpOLEObject property returns a Long value representing a pointer to an IOLEObject. Read-only.

Note

The LpOLEObject property has been deprecated in Access 2010. Use the VarOLEObject property to determine the memory of an OLE object.

Syntax

expression .LpOleObject

expression A variable that represents an ObjectFrame object.

Remarks

You can use the LpOLEObject property to refer to the address of the active OLE object. If no object is displayed, the setting is 0.

This property setting isn't available in Design view and is read-only in other views.

In the OLE dynamic link libraries (DLLs), many function calls require the address of the OLE object as an argument. You can pass the value specified by the LpOLEObject property when making application programming interface (API) calls to the OLE DLLs.

If an API call is made to a function that makes a callback to the control, the results will be unpredictable.

Example

To return the value of the LpOLEObject property for the "Customer Picture" OLE control on the "Order Entry" form, you can use the following:

Dim l As Long 
l = Forms("Order Entry").Controls("Customer Picture").LpOleObject