Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

AtlAxAttachControl

 

Attaches a previously created control to the specified window.

System_CAPS_importantImportant

This function cannot be used in applications that execute in the Windows Runtime.


      ATLAPI AtlAxAttachControl(
IUnknown* pControl,
HWND hWnd,
IUnknown** ppUnkContainer 
);

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.

One of the standard HRESULT values.

Use AtlAxCreateControlEx and AtlAxCreateControl to simultaneously create and attach a control.

System_CAPS_noteNote

The control object being attached must be correctly initialized before calling AtlAxAttachControl.

Requirements

Header: atlhost.h

Show: