毕设日记(一)
来源:互联网 发布:美国债券市场数据 编辑:程序博客网 时间:2024/04/29 18:09
本来早就发布在了windows live space里,可是又觉得这样对不起csdn的blog,还是把它们都贴过来的吧。虽然有点肤浅,都是最基本的常识,不过虽然我是菜鸟呢,唉
毕业设计开始一段时间了。经过了前一阶段的需求分析和设计,终于开始编码,然而……好久不写,生疏掉了,于是赶紧把遇到的问题写下来,以防以后忘掉。
1、OnCreate/OnSize/OnInitDialog哪个先执行?
下面是从MSDN上选的:
OnCreate:The framework calls this member function when an application requests that the windows windows be created by calling the Create or CreateEx member function. The CWnd object receives this member function to perform any needed initialization before it becomes visible.
OnSize: The framework calls this member function after the window's size has changed.
OnInitDialog:This member function is called in response to the WM_INITDIALOG message. This message is sent to the dialog box during the Create, CreateIndirect, or DoModal calls, which occur immediately before the dialog box is displayed.
从MSDN的解释来看,OnCreate应该是在OnInitDialog之前被调用的。但是和OnSize的顺序还是看不太明显。于是……哈哈,我们有MessageBox
测试的结果是 OnCreate > OnSize > OnInitDialog
看到的也可以去试试,万一我说错,赶紧告诉我。
2、Windows Mobile中字符串必须是Unicode
在开发MFC智能设备应用程序时,百事不爽的MessageBox("Hello world!")竟然不给面子,出错了。于是……_T("Hello World!"),看来_T()这个东西还是很好很强大的。同样的,在下面的结构里也得_T一把
CString str;
str.Format(_T("%d"), a);
- 毕设日记(一)
- 毕设日记(二)
- 大学的最后时光---我的毕设日记(一)
- 晨间日记――为梦 想而设的仪式(一)
- 毕设开发记录(一)
- 我的毕设路程(一)
- 毕设日记(三)——不要让SIP覆盖了TextBox
- 毕设日记之小白bug之SSH(1)
- 毕设小结(一)Android程序包验证
- word毕设论文制作——封面(一)
- (一)单片机STM32电力电子毕设
- 大学的最后时光---我的毕设日记(二)
- 汉城日记(一)
- 装修日记(一 )
- 西安日记(一)
- Linux 日记(一)
- 开发日记(一)
- 创业日记(一)
- 游戏防沉迷软件[适用于所有单机/网络游戏][C源码][自写][win32平台]
- Ubuntu下常用软件[持续更新]
- 在东软正式培训的第一周
- 关于设计模式的一点想法
- 设计模式学习C#之 简单工厂模式 to be continued
- 毕设日记(一)
- CMM
- 设计模式学习C# 之 工厂方法模式 to be continued
- 毕业设计--DAY ONE
- 毕设日记(二)
- java多线程使用总结
- problem 1797
- 关于webwork中continuation用法的说明
- 首次安装IIS5.1后不能识别http://192.168.*.*