AtlAxAttachControl
Attaches a previously created control to the specified window.
ATLAPI AtlAxAttachControl(
IUnknown* pControl,
HWND hWnd,
IUnknown** ppUnkContainer
);
Parameters
pControl
[in] A pointer to the IUnknown of the control.hWnd
[in] Handle to the window that will host the control.ppUnkContainer
[out] A pointer to a pointer to the IUnknown of the container object.
Return Value
One of the standard HRESULT values.
Remarks
Use AtlAxCreateControlEx and AtlAxCreateControl to simultaneously create and attach a control.
注意
The control object being attached must be correctly initialized before calling AtlAxAttachControl.
Requirements
Header: atlhost.h