本帖最后由 panderang 于 2013-04-20 16:35:40 编辑

解决方案 »

  1.   

    还有个解决方法,
    在ProcessShellCommand(cmdInfo)前加入 m_bLoadWindowPlacement = FALSE;或者重载程序类的这两个函数 让其直接返回FALSE:
    BOOL CPCApp::LoadWindowPlacement(CRect& rectNormalPosition, int& nFflags, int& nShowCmd)
    {
    // TODO: 在此添加专用代码和/或调用基类
    return FALSE;
    //return CWinAppEx::LoadWindowPlacement(rectNormalPosition, nFflags, nShowCmd);
    }BOOL CPCApp::StoreWindowPlacement(const CRect& rectNormalPosition, int nFflags, int nShowCmd)
    {
    // TODO: 在此添加专用代码和/或调用基类
    return FALSE;
    //return CWinAppEx::StoreWindowPlacement(rectNormalPosition, nFflags, nShowCmd);
    }