各位高手,vc编程时,想让对话框总显示在top_level,应该怎么做?

解决方案 »

  1.   

    SetWindowAttribute(TRUE); 
      

  2.   

    SetWindowPos(m_hWnd,HWND_TOPMOST……
      

  3.   

    SetWindowPos(&wndTopMost,0,0,0,0,SWP_NOSIZE|SWP_NOMOVE);
      

  4.   

    this->SetWindowPos(&wndTopMost,0,0,800,600,SWP_NOREDRAW);
      

  5.   

    SetWindowPos(&wndTopMost,0,0,1024,768,SWP_NOREDRAW+SWP_NOSIZE);
      

  6.   

    SetWindowPos(&wndTopMost,0,0,0,0,SWP_NOSIZE|SWP_NOMOVE);这个 放在 InitialDialog 中就可以了!试试?
      

  7.   

    this->SetWindowPos(&wndTopMost,0,0,800,600,SWP_NOREDRAW);
      

  8.   

    BOOL CMyDlg::OnInitDialog()
        {
             CDialog::OnInitDialog();         // Add "About..." menu item to system menu.         SetWindowPos(&wndTopMost,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE);//这句
             // TODO: Add extra initialization here
      
             return TRUE;  // return TRUE  unless you set the focus to a control
        }