Dhananjayan Level: Trainee
 Registered: 08-09-2005 Posts: 2
|
Problem Z-Ording the Winow [ SetWindowPos() ]
I have a problem regarding to my Application. The requirement is to display the window to the top of the Z-Order of the Windows. So I use SetWindowPos() method for it. But the Problem is that the windows does not become active programatically. It is an MFC application.
::ShowWindow( m_hWnd, SW_RESTORE );
::SetWindowPos( m_hWnd,HWND_TOPMOST,0,0,0,0, SWP_NOSIZE|SWP_NOREPOSITION );
::SetWindowPos( m_hWnd,HWND_NOTOPMOST,0,0,0,0, SWP_NOSIZE|SWP_NOREPOSITION );
::SetFocus ( m_hWnd);
::SetActiveWindow( m_hWnd );
____________________________
Dhana
|