有个功能要用的...

解决方案 »

  1.   

    CRect rcWin;
    GetWindowRect(&rcWin);
    // rcWin.Wdith();
    // rcWin.Heigth();
      

  2.   

    我原来的程序没有 include afxwin.h 这个文件的. 
    还有其他的实现方法么?
    我想直接用API 不用MFC
    ^_^ 谢谢
      

  3.   

    这个函数有API啊,MFC也是直接掉的API,只是多传个句柄嘛。
      

  4.   

    this is an API functionBOOL GetWindowRect(
      HWND hWnd,      // handle to window
      LPRECT lpRect   // window coordinates
    );params
    hWnd 
    [in] Handle to the window. 
    lpRect 
    [out] Pointer to a RECT structure that receives the screen coordinates of the upper-left and lower-right corners of the window. 
    may you succeed !