MFC——属性页对话框的创建
2015-11-04 21:01
281 查看
1,首先创建几个属性页对话框,并且修改其的ID号
2,使用类向导选项建立相关属性对话框页的类,这个类基于CPropertyPage类,就可以把一个界面与一个类相关起来
3,根据MSDN手册可知:
Objects of class CPropertySheet represent property sheets, otherwise known as tab dialog boxes. A property sheet consists of a CPropertySheet object and one or more CPropertyPage objects. A property sheet is displayed by the framework as a window with a set of tab indices, with which the user selects the current page, and an area for the currently selected page.
必须建立一个基于 CPropertySheet类的子类。
4,Even though CPropertySheet is not derived from CDialog, managing a CPropertySheet object is similar to managing a CDialog object. For example, creation of a property sheet requires two-part construction: call the constructor, and then call DoModal for a modal property sheet or Create for a modeless property sheet. CPropertySheet has two types of constructors: CPropertySheet::Construct and CPropertySheet::CPropertySheet.
将创建完的属性对话框页加载进入这个类中(新建属性对话框页的几个相关变量,在其构造函数中使用AddAddPage函数)
5,在View类中新建一个对话框,用于显示列表
2,使用类向导选项建立相关属性对话框页的类,这个类基于CPropertyPage类,就可以把一个界面与一个类相关起来
3,根据MSDN手册可知:
Objects of class CPropertySheet represent property sheets, otherwise known as tab dialog boxes. A property sheet consists of a CPropertySheet object and one or more CPropertyPage objects. A property sheet is displayed by the framework as a window with a set of tab indices, with which the user selects the current page, and an area for the currently selected page.
必须建立一个基于 CPropertySheet类的子类。
4,Even though CPropertySheet is not derived from CDialog, managing a CPropertySheet object is similar to managing a CDialog object. For example, creation of a property sheet requires two-part construction: call the constructor, and then call DoModal for a modal property sheet or Create for a modeless property sheet. CPropertySheet has two types of constructors: CPropertySheet::Construct and CPropertySheet::CPropertySheet.
将创建完的属性对话框页加载进入这个类中(新建属性对话框页的几个相关变量,在其构造函数中使用AddAddPage函数)
5,在View类中新建一个对话框,用于显示列表
相关文章推荐
- 不积跬步无以至千里-2
- 软件文档概述(一)
- 在AngularJs中怎么设置请求头信息(headers)及不同方法的比较
- thinkphp解决表单令牌问题
- web.xml 通过contextConfigLocation配spring 的方式
- EM-期望最大化算法
- 黑马程序员—Java基础—IO4
- win7/9/10 U盘启动盘的制作
- uiautomator使用
- c++成员函数指针
- October——I Will Talk
- 修改了系统自带头文件后,Xcode会报错
- 第三节:欠拟合与过拟合的概念
- Ajax再回首
- 手机充电器电路图应用讲解
- Android滚动条修改的练习记录
- 学习之前,先讲解下各种服务器模型,还有muduo的服务器模型
- 二元一次不定方程
- iOS开发设计模式详解
- HelloWorld