⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 subject_23670.htm

📁 一些关于vc的问答
💻 HTM
字号:
<p>
序号:23670 发表者:brown 发表日期:2002-12-05 18:41:52
<br>主题:請問如何讓 vc 產生的 MDI 骨幹不主動 new 一份 doc?
<br>内容:我用 vc wizard 產生一份 MDI 骨幹,執行時他都會出現 一個 child window.<BR>請問我應該在何處修改,讓他不會自動產生哪?我想作自己的view 與 doc。我想做一個經<BR>RS232 控制 51ICE 的程式。 看來還有一大段路要走。<BR>謝謝。<BR>
<br><a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p>
<hr size=1>
<blockquote><p>
<font color=red>答案被接受</font><br>回复者:晚风也渡 回复日期:2002-12-05 18:54:28
<br>内容:在CXXApp::InitInstance()中的<BR>CCommandLineInfo cmdInfo;<BR> ParseCommandLine(cmdInfo);中间加入<BR>cmdInfo.m_nShellCommand=CCommandLineInfo::FileNothing;
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
回复者:tjhe 回复日期:2002-12-05 18:58:52
<br>内容:在应用程序类***App的InitInstance()函数中的如下语句:<BR>// Dispatch commands specified on the command line<BR>if (!ProcessShellCommand(cmdInfo))<BR>&nbsp;&nbsp; return FALSE;<BR>前加一句&nbsp;&nbsp;&nbsp;&nbsp;cmdInfo.m_nShellCommand = CCommandLineInfo::FileNothing;<BR><BR>即:<BR>&nbsp;&nbsp;&nbsp;&nbsp;cmdInfo.m_nShellCommand = CCommandLineInfo::FileNothing;<BR><BR>&nbsp;&nbsp;&nbsp;&nbsp;// Dispatch commands specified on the command line<BR>&nbsp;&nbsp;&nbsp;&nbsp;if (!ProcessShellCommand(cmdInfo))<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return FALSE;<BR>
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
回复者:brown 回复日期:2002-12-06 08:00:36
<br>内容:Hi,<BR>&nbsp;&nbsp;晚风也渡 與 tjhe. 謝謝兩位的回答,<BR>兩位的方法都可行,我要查看看他們的差異在哪裡。<BR>謝謝。<BR><BR>Brown.
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
回复者:brown 回复日期:2002-12-06 08:23:45
<br>内容:Hi,<BR>&nbsp;&nbsp;晚风也渡 與 tjhe.<BR>我在 MSDN 裡找到如下敘述,所以是 tjhe 的方式為 MSDN 裡的建議.<BR>我想晚风也渡 是提前設定,但仍然是到了ProcessShellCommand(cmdInfo)<BR>才發生作用.<BR>謝謝兩位。<BR><BR>CCommandLineInfo::FileNothing&nbsp;&nbsp; Turns off the display of a new MDI child window on startup. By design, AppWizard generated MDI applications display a new child window on startup. To turn off this feature, an application can use CCommandLineInfo::FileNothing as the shell command when calling ProcessShellCommand. ProcessShellCommand is called by the InitInstance( ) of all CWinApp derived classes. <BR>Example<BR><BR>BOOL CMyWinApp::InitInstance()<BR>{<BR>...<BR>// Parse command line for standard shell commands, DDE, file open<BR>&nbsp;&nbsp; CCommandLineInfo cmdInfo;<BR>&nbsp;&nbsp; ParseCommandLine(cmdInfo);<BR>// DON'T display a new MDI child window during startup!!!<BR>&nbsp;&nbsp; cmdInfo.m_nShellCommand = CCommandLineInfo::FileNothing;<BR>// Dispatch commands specified on the command line<BR>&nbsp;&nbsp; if (!ProcessShellCommand(cmdInfo))<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return FALSE;<BR>...<BR>};<BR><BR>
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -