OleCreatePropertyFrame  122OI_U

Invokes a new property frame, that is, a property sheet dialog box, whose parent is hwndOwner, where the dialog is positioned at the point (x,y) in the parent window and has the caption lpszCaption.

STDAPI OleCreatePropertyFrame(

    HWND hwndOwner,

//Parent window of property sheet dialog box

    UINT x,

//Horizontal position for dialog box

    UINT y,

//Vertical position for dialog box

    LPCOLESTR lpszCaption,

//Pointer to the dialog box caption

    ULONG cObjects,

//Number of object pointers in lplpUnk

    LPUNKNOWN FAR* lplpUnk,

//Pointer to the objects for property sheet

    ULONG cPages,

//Number of property pages in lpPageClsID

    LPCLSID lpPageClsID,

//Array of CLSIDs for each property page

    LCID lcid,

//Locale identifier for property sheet locale

    DWORD dwReserved,

//Reserved

    LPVOID lpvReserved

//Reserved

   );

 

 

Parameters

hwndOwner

[in] Parent window of the resulting property sheet dialog box.

x

[in] Horizontal position for the dialog box relative to hwndOwner.

y

[in] Vertical position for the dialog box relative to hwndOwner.

lpszCaption

[in] Pointer to the string used for the caption of the dialog box.

cObjects

[in] Number of object pointers passed in lplpUnk.

lplpUnk

[in] An array of IUnknown pointers on the objects for which this property sheet is being invoked. The number of elements in the array is specified by cObjects. These pointers are passed to each property page through IPropertyPage::SetObjects1DNH5AP.

cPages

[in] Number of property pages specified in lpPageCIsID.

lpPageCIsID

[in] Array of size cPages containing the CLSIDs of each property page to display in the property sheet.

lcid

[in] Locale identifier to use for the property sheet. Property pages can retrieve this identifier through IPropertyPageSite::GetLocaleID5_JD__O.

dwReserved

[in] Reserved for future use; must be zero.

lpvReserved

[in] Reserved for future use; must be NULL.

 

Return Values

This function supports the standard return values E_INVALIDARG, E_OUTOFMEMORY, and E_UNEXPECTED, as well as the following:

S_OK

The dialog box was invoked and operated successfully.

E_POINTER

The address in lpszCaption, lplpUnk, or lpPageCIsID is not valid. For example, any one of them may be NULL.

 

Remarks

The property pages to be displayed are identified with lpPageClsID, which is an array of cPages CLSID values. The objects that are affected by this property sheet are identified in lplpUnk, an array of size cObjects containing IUnknown pointers.

This function always creates a modal dialogbox  and does not return until the dialog box is closed.

See Also

OleCreatePropertyFrameIndirect