Windows程序的执行过程:
首先,Windows程序是以WinMain函数作为它的入口函数的,
WinMain函数类似c语言中的main函数,其功能是完成一系列的定义和初始化,并产生消息循环。
函数原型:
int WINAPI WinMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPSTR lpCmdLine,int nCmdShow);
参数:
hInstance:当前应用程序实例句柄;
hPrevInstance:先前应用程序实例句柄;
lpCmdLine:命令行;
nCmdShow:窗口的显示状态:可以是以下值
Value
SW_HIDE
SW_MAXIMIZE
SW_MINIMIZE Meaning Hides the window and activates another window. Maximizes the specified window. Minimizes the specified window and activates the next top-level window
in the Z order.
Activates and displays the window. If the window is minimized or
maximized, the system restores it to its original size and position. An
application should specify this flag when restoring a minimized window.
Activates the window and displays it in its current size and position.
Activates the window and displays it as a maximized window.
Activates the window and displays it as a minimized window.
Displays the window as a minimized window.
This value is similar to SW_SHOWMINIMIZED, except the window is
not activated.
Displays the window in its current size and position.
This value is similar to SW_SHOW, except the window is not activated. SW_RESTORE SW_SHOW SW_SHOWMAXIMIZED SW_SHOWMINIMIZED SW_SHOWMINNOACTIVE SW_SHOWNA
MFC学习总结 (常用技巧) 95页 1下载券 MFC学习总结(重要) 暂无评价 55页 1下载券 MFC学习总结技巧 暂无评价 95页 1下载券 喜欢此文档的还喜欢 MFC学习总结3...
MFC 学习总结技巧 1."属性页的添加: 创建对话框的类,该类要从 CpropertyPage ...assert()的功能类似,它是 ANSI C 标准中规定的函数,它与 ASSERT 的一个重要...
MFC学习总结_学习总结_总结/汇报_实用文档。自己总结的一点MFC知识,希望帮助大家点击按钮链接网站地址(VS2005): void ChyperlinkDlg::OnBnClickedButton1() { // ...
学习总结(3)(转载) (3)(转载 MFC 学习总结(3)(转载) [ 2008-1-28 14:...()的功能类似, 它是 ANSI C 标准中规定的函数, 它与 ASSERT 的一个重要...
{ HBRUSH hbr = CDialog::OnCtlColor(pDC, pWnd, nCtlColor); return hbr; } } 第二种方法(对应于 IDC_EDIT2): 利用 MFC 4.0 的新特性: Message ...
下面摘抄一些原文,并总结了一些学习心得,权当作一点小 小的学习收获吧,也希望...机密的“麻烦事儿”,正是我认为掌控 MFC 这套 Application Frameworks 的重要...
MFC学习总结(重要) 暂无评价 55页 1财富值喜欢此文档的还喜欢 ...mfc学习总结 隐藏>> 3月6日 1、MCI(Media Control Interface)媒体控制接口提供...
mfc近期学习总结_学习总结_总结/汇报_实用文档 暂无评价0人阅读0次下载举报文档 mfc近期学习总结_学习总结_总结/汇报_实用文档。sdf...
MFC学习总结(重要) 暂无评价 55页 1财富值 MFC学习总结技巧 暂无评价 95页 1...MFC学习总结MFC学习总结隐藏>> 1."属性页的添加: . 属性页的添加 属性页的添...
mfc学习心得_工学_高等教育_教育专区。1.在 SDI 的窗口输出“hello,world"字样...应用程序中最重要的用户界面元素之一,是与用户交互 的重要手段,在程序运行过程...
热门文档