共用方式為


CWindow::BringWindowToTop

的疊置順序的最頂端視窗。

BOOL BringWindowToTop( ) throw();

備註

請參閱在 Windows SDK的 BringWindowToTop

範例

//The following example attaches an HWND to the CWindow object and 
//calls CWindow::BringWindowToTop() to bring the window to the top 
//of the z-order.

CWindow myWindow;
myWindow.Attach(hWnd);
BOOL bOnTop = myWindow.BringWindowToTop();

//check if we could bring the window on top
if(bOnTop)
{
   //Do something
}

需求

Header: atlwin.h

請參閱

參考

CWindow 類別

CWindow::MoveWindow

CWindow::SetWindowPos