Export (0) Print
Expand All

CustomControl.LpOleObject Property (Access)

This documentation is preliminary and is subject to change.

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 Note

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

expression .LpOleObject

expression A variable that represents a CustomControl object.

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.

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

Community Additions

Show:
© 2014 Microsoft