CWindow::Detach

Rimuove m_hWnd dall'oggetto CWindow e imposta m_hWnd a NULL.

HWND Detach( ) throw();

Valore restituito

HWND associato all'oggetto CWindow.

Esempio

//The following example attaches an HWND to the CWindow object and 
//later detaches the CWindow object from the HWND when no longer needed

CWindow myWindow;
myWindow.Attach(hWnd);

//call CWindow wrappers

//We don't need the C++ object any more, so detach it from the HWND.
myWindow.Detach(); 

Requisiti

Header: atlwin.h

Vedere anche

Riferimenti

Classe di CWindow

CWindow::Attach