转自 http://topic.youkuaiyun.com/t/20051101/11/4363491.html
当登陆成功时,才能看到后面的view
==这里有个非常重要的问题,你的登录对话框启动是在
CCommandLineInfo cmdInfo;
ParseCommandLine(cmdInfo);
// Dispatch commands specified on the command line
if (!ProcessShellCommand(cmdInfo))
return FALSE;
之前还是之后?如果是之前,那么此时文档对象还没有生成,你不可能得到。如果是之后,那么可以用以下方式:
CMainFrame *pFrame = (CMainFrame*)(AfxGetApp()-> m_pMainWnd);
C**Doc *pDoc = pFrame-> GetActiveDocument();
这里的pDoc就是你要的文档对象了。C**Doc是你的文档类名称