RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
AxCtrls.GetOlePicture Function

Creates an OLE picture object that is directly mapped to a native TPicture.

Pascal
procedure GetOlePicture(Picture: TPicture; var OlePicture: IPictureDisp);
C++
GetOlePicture(TPicture Picture, IPictureDisp OlePicture);

AxCtrls

OLE conventions implement pictures as automation objects that contain the properties of the picture. This routine creates an adapter object that maps the properties of a native VCL TPicture into an OLE picture object, thereby allowing an OLE client to access the picture properties of a VCL control. Call this function when you implement a method that retrieves a TPicture value from a VCL object and returns it as an OLE picture. 

The Picture parameter is a pointer to the native TPicture. This can be the Picture property of a VCL control. The OLE picture is returned in the OlePicture parameter. The resulting OLE picture object is a direct connection to the native VCL picture, so changing the OLE picture's properties will change the TPicture's properties, and vice-versa. 

 

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!