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

📄 group__dialog__fns.htm

📁 MINIGUI1.6开发API
💻 HTM
📖 第 1 页 / 共 5 页
字号:
        <tr>          <td class="md" nowrap valign="top">void GUIAPI CheckRadioButton           </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="md" nowrap valign="top"><a class="el" href="group__handles.htm#ga1">HWND</a>&nbsp;</td>          <td class="mdname" nowrap> <em>hDlg</em>, </td>        </tr>        <tr>          <td class="md" nowrap align="right"></td>          <td class="md"></td>          <td class="md" nowrap>int&nbsp;</td>          <td class="mdname" nowrap> <em>idFirstButton</em>, </td>        </tr>        <tr>          <td class="md" nowrap align="right"></td>          <td class="md"></td>          <td class="md" nowrap>int&nbsp;</td>          <td class="mdname" nowrap> <em>idLastButton</em>, </td>        </tr>        <tr>          <td class="md" nowrap align="right"></td>          <td class="md"></td>          <td class="md" nowrap>int&nbsp;</td>          <td class="mdname" nowrap> <em>idCheckButton</em></td>        </tr>        <tr>          <td class="md"></td>          <td class="md">)&nbsp;</td>          <td class="md" colspan="2"></td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Adds a check mark to (checks) a specified radio button in a group and removes a check mark from (clears) all other radio buttons in the group. <p>This function adds a check mark to (checks) the specified radio button <em>idCheckButton</em> in a group between <em>idFirstButton</em> and <em>idLastButton</em>, and removes a check mark from (clears) all other radio buttons in the group.<p><dl compact><dt><b>Parameters:</b></dt><dd>  <table border="0" cellspacing="2" cellpadding="0">    <tr><td valign="top"></td><td valign="top"><em>hDlg</em>&nbsp;</td><td>The handle to the dialog box. </td></tr>    <tr><td valign="top"></td><td valign="top"><em>idFirstButton</em>&nbsp;</td><td>The identifier of the first control in the group. </td></tr>    <tr><td valign="top"></td><td valign="top"><em>idLastButton</em>&nbsp;</td><td>The identifier of the last control in the group. </td></tr>    <tr><td valign="top"></td><td valign="top"><em>idCheckButton</em>&nbsp;</td><td>The identifier of the control to be checked.</td></tr>  </table></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__dialog__fns.htm#ga20">CheckDlgButton</a> </dd></dl>    </td>  </tr></table><a class="anchor" name="ga4" doxytag="window.h::CreateMainWindowIndirectParam"></a><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top"><a class="el" href="group__handles.htm#ga1">HWND</a> GUIAPI CreateMainWindowIndirectParam           </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="md" nowrap valign="top"><a class="el" href="struct__DLGTEMPLATE.htm">PDLGTEMPLATE</a>&nbsp;</td>          <td class="mdname" nowrap> <em>pDlgTemplate</em>, </td>        </tr>        <tr>          <td class="md" nowrap align="right"></td>          <td class="md"></td>          <td class="md" nowrap><a class="el" href="group__handles.htm#ga1">HWND</a>&nbsp;</td>          <td class="mdname" nowrap> <em>hOwner</em>, </td>        </tr>        <tr>          <td class="md" nowrap align="right"></td>          <td class="md"></td>          <td class="md" nowrap><a class="el" href="group__window__create__fns.htm#ga0">WNDPROC</a>&nbsp;</td>          <td class="mdname" nowrap> <em>WndProc</em>, </td>        </tr>        <tr>          <td class="md" nowrap align="right"></td>          <td class="md"></td>          <td class="md" nowrap><a class="el" href="group__win32__types.htm#ga9">LPARAM</a>&nbsp;</td>          <td class="mdname" nowrap> <em>lParam</em></td>        </tr>        <tr>          <td class="md"></td>          <td class="md">)&nbsp;</td>          <td class="md" colspan="2"></td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Uses a dialog template to create a modeless main window and controls in it, and pass a parameter to the window procedure. <p>This function uses a dialog template pointed to by <em>pDlgTemplate</em> to create a modeless main window and controls in it. The parameter specified by <em>lParam</em> will be passed to the window procedure as the second paramter of MSG_INITDIALOG message.<p><dl compact><dt><b>Parameters:</b></dt><dd>  <table border="0" cellspacing="2" cellpadding="0">    <tr><td valign="top"></td><td valign="top"><em>pDlgTemplate</em>&nbsp;</td><td>The pointer to a DLGTEMPLATE structure. </td></tr>    <tr><td valign="top"></td><td valign="top"><em>hOwner</em>&nbsp;</td><td>The handle to the hosting main window. </td></tr>    <tr><td valign="top"></td><td valign="top"><em>WndProc</em>&nbsp;</td><td>The window procedure of the new main window. </td></tr>    <tr><td valign="top"></td><td valign="top"><em>lParam</em>&nbsp;</td><td>The parameter will be passed to the window procedure.</td></tr>  </table></dl><dl compact><dt><b>Returns:</b></dt><dd>Handle to the new main window, HWND_INVALID on error.</dd></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__dialog__fns.htm#ga5">DestroyMainWindowIndirect</a>, <a class="el" href="group__dialog__fns.htm#ga6">DialogBoxIndirectParam</a>, <a class="el" href="group__dialog__fns.htm#ga2">DLGTEMPLATE</a> </dd></dl>    </td>  </tr></table><a class="anchor" name="ga8" doxytag="window.h::DestroyAllControls"></a><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top">void GUIAPI DestroyAllControls           </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="md" nowrap valign="top"><a class="el" href="group__handles.htm#ga1">HWND</a>&nbsp;</td>          <td class="mdname1" valign="top" nowrap> <em>hWnd</em>          </td>          <td class="md" valign="top">&nbsp;)&nbsp;</td>          <td class="md" nowrap></td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Destroys all controls in a window. <p>This function destroys all controls (child windows) in a window.<p><dl compact><dt><b>Parameters:</b></dt><dd>  <table border="0" cellspacing="2" cellpadding="0">    <tr><td valign="top"></td><td valign="top"><em>hWnd</em>&nbsp;</td><td>The handle to the window.</td></tr>  </table></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__control__fns.htm#ga2">DestroyWindow</a> </dd></dl>    </td>  </tr></table><a class="anchor" name="ga5" doxytag="window.h::DestroyMainWindowIndirect"></a><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top"><a class="el" href="group__simple__types.htm#ga0">BOOL</a> GUIAPI DestroyMainWindowIndirect           </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="md" nowrap valign="top"><a class="el" href="group__handles.htm#ga1">HWND</a>&nbsp;</td>          <td class="mdname1" valign="top" nowrap> <em>hMainWin</em>          </td>          <td class="md" valign="top">&nbsp;)&nbsp;</td>          <td class="md" nowrap></td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Destroys a main window created by <em>CreateMainWindowIndirectParam</em>. <p>This function destroys the main window which was created by <em>CreateMainWindowIndirectParam</em> function.<p><dl compact><dt><b>Parameters:</b></dt><dd>  <table border="0" cellspacing="2" cellpadding="0">    <tr><td valign="top"></td><td valign="top"><em>hMainWin</em>&nbsp;</td><td>The handle to the main window.</td></tr>  </table></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__dialog__fns.htm#ga4">CreateMainWindowIndirectParam</a> </dd></dl>    </td>  </tr></table><a class="anchor" name="ga6" doxytag="window.h::DialogBoxIndirectParam"></a><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top">int GUIAPI DialogBoxIndirectParam           </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="md" nowrap valign="top"><a class="el" href="struct__DLGTEMPLATE.htm">PDLGTEMPLATE</a>&nbsp;</td>          <td class="mdname" nowrap> <em>pDlgTemplate</em>, </td>        </tr>        <tr>          <td class="md" nowrap align="right"></td>          <td class="md"></td>          <td class="md" nowrap><a class="el" href="group__handles.htm#ga1">HWND</a>&nbsp;</td>          <td class="mdname" nowrap> <em>hOwner</em>, </td>        </tr>        <tr>          <td class="md" nowrap align="right"></td>          <td class="md"></td>          <td class="md" nowrap><a class="el" href="group__window__create__fns.htm#ga0">WNDPROC</a>&nbsp;</td>          <td class="mdname" nowrap> <em>DlgProc</em>, </td>        </tr>        <tr>          <td class="md" nowrap align="right"></td>          <td class="md"></td>          <td class="md" nowrap><a class="el" href="group__win32__types.htm#ga9">LPARAM</a>&nbsp;</td>          <td class="mdname" nowrap> <em>lParam</em></td>        </tr>        <tr>          <td class="md"></td>          <td class="md">)&nbsp;</td>          <td class="md" colspan="2"></td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Creates a modal dialog box from a dialog box template in memory. <p>This function creates a modal dialog box from a dialog box template in memory. Before displaying the dialog box, the function passes an application-defined value to the dialog box procedure as the second parameter of the MSG_INITDIALOG message. An application can use this value to initialize the controls in the dialog box.<p><dl compact><dt><b>Parameters:</b></dt><dd>  <table border="0" cellspacing="2" cellpadding="0">    <tr><td valign="top"></td><td valign="top"><em>pDlgTemplate</em>&nbsp;</td><td>The pointer to a DLGTEMPLATE structure. </td></tr>    <tr><td valign="top"></td><td valign="top"><em>hOwner</em>&nbsp;</td><td>The handle to the hosting main window. </td></tr>    <tr><td valign="top"></td><td valign="top"><em>DlgProc</em>&nbsp;</td><td>The window procedure of the new dialog box. </td></tr>    <tr><td valign="top"></td><td valign="top"><em>lParam</em>&nbsp;</td><td>The parameter will be passed to the window procedure.</td></tr>  </table></dl><dl compact><dt><b>Returns:</b></dt><dd>Return value of the dialog box, i.e., the second argument passed to EndDialog function which closes the dialog box.</dd></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__dialog__fns.htm#ga7">EndDialog</a>, <a class="el" href="group__dialog__fns.htm#ga4">CreateMainWindowIndirectParam</a>, <a class="el" href="group__dialog__fns.htm#ga2">DLGTEMPLATE</a></dd></dl>Example:<p><div class="fragment"><pre class="fragment"><span class="comment">/*</span><span class="comment"> * The following code defines the dialog box callback procedure</span><span class="comment"> * and displays the dialog box by calling DialogBoxIndirectParam function.</span><span class="comment"> */</span><span class="keyword">static</span> <span class="keywordtype">int</span> InitDialogBoxProc (<a class="code" href="group__handles.htm#ga1">HWND</a> hDlg, <span class="keywordtype">int</span> message, <a class="code" href="group__win32__types.htm#ga8">WPARAM</a> wParam, <a class="code" href="group__win32__types.htm#ga9">LPARAM</a> lParam){    <span class="keywordflow">switch</span> (message) {    <span class="keywordflow">case</span> <a class="code" href="group__ctrl__msgs.htm#ga4">MSG_INITDIALOG</a>:        <span class="keywordflow">return</span> 1;            <span class="keywordflow">case</span> <a class="code" href="group__ctrl__msgs.htm#ga1">MSG_COMMAND</a>:        <span class="keywordflow">switch</span> (wParam) {        <span class="keywordflow">case</span> IDOK:        <span class="keywordflow">case</span> IDCANCEL:            <a class="code" href="group__dialog__fns.htm#ga7">EndDialog</a> (hDlg, wParam);            <span class="keywordflow">break</span>;        }        <span class="keywordflow">break</span>;            }        <span class="keywordflow">return</span> <a class="code" href="group__window__create__fns.htm#ga20">DefaultDialogProc</a> (hDlg, message, wParam, lParam);}<span class="keyword">static</span> <span class="keywordtype">void</span> InitDialogBox (<a class="code" href="group__handles.htm#ga1">HWND</a> hWnd){    <span class="comment">/* Assoiciate the dialog with the controls */</span>    DlgInitProgress.<a class="code" href="struct__DLGTEMPLATE.htm#o10">controls</a> = CtrlInitProgress;        <span class="comment">/* Display the dialog box and wait */</span>    <a class="code" href="group__dialog__fns.htm#ga6">DialogBoxIndirectParam</a> (&amp;DlgInitProgress, hWnd, InitDialogBoxProc, 0L);}</pre></div>     </td>  </tr></table><a class="anchor" name="ga7" doxytag="window.h::EndDialog"></a><p>

⌨️ 快捷键说明

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