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

📄 l3.htm

📁 C++Builder教学大全
💻 HTM
字号:
 

<html>

<head>

<title>怎样以最小化方式启动程序</title>

<meta http-equiv="目录类型" content="文本/html; 字符集=gb2312">

</head>

<body bgcolor="#FFFFFF">

<table width="100%" border="0" height="285">

  <tr> 

    <td height="35"> 

      <div align="center" class="p14"><font color="#000000">怎样以最小化方式启动程序</font></div>

    </td>

  </tr>

  <tr valign="top"> 

    <td>

      <p><font color="#000000">可以调用Application-&gt;Minimize函数来最小化应用程序到任务条。如何你希望你的程序启动时就最小化,只需在调用Run方法前调用Application-&gt;Minimize就行了。</font></p>

      <pre><span style="BACKGROUND-COLOR: silver"><font color="#000000">WINAPI WinMain(HINSTANCE, HINSTANCE, LPSTR, </font></span><font color="#000000"><span style="BACKGROUND-COLOR: silver"><b>int</b>)</span>

<span style="BACKGROUND-COLOR: silver">{</span>

<span style="BACKGROUND-COLOR: silver">    <b>try</b></span>

<span style="BACKGROUND-COLOR: silver">    {</span>

<span style="BACKGROUND-COLOR: silver">        Application-&gt;Initialize();</span>

<span style="BACKGROUND-COLOR: silver">        Application-&gt;CreateForm(<b>__classid</b>(TForm1), &amp;Form1);</span>

<span style="BACKGROUND-COLOR: silver">        Application-&gt;Minimize();  //以最小化方式启动</span>

<span style="BACKGROUND-COLOR: silver">        Application-&gt;Run();</span>

<span style="BACKGROUND-COLOR: silver">    }</span>

<span style="BACKGROUND-COLOR: silver">    <b>catch</b> (Exception &amp;exception)</span>

<span style="BACKGROUND-COLOR: silver">    {</span>

<span style="BACKGROUND-COLOR: silver">        Application-&gt;ShowException(&amp;exception);</span>

<span style="BACKGROUND-COLOR: silver">    }</span>

<span style="BACKGROUND-COLOR: silver">    <b>return</b> 0;</span>

<span style="BACKGROUND-COLOR: silver">}</span></font></pre>

      </td>

  </tr>

</table>

<br>

</body>

</html>

⌨️ 快捷键说明

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