CWindow::Detach
分离 CWindow 对象的 m_hWnd 并将 m_hWnd 到 NULL。
HWND Detach( ) throw();
返回值
HWND 与 CWindow 对象。
示例
//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();
要求
Header: atlwin.h