CPropertySheet tab page realizes switching between various CPropertyPage pages_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 11:50:28
Original
1542 people have browsed it

Source: http://bbs.csdn.net/topics/390973895

There are three methods:

The first one

It is your CPropertyPage that passes the original CPropertySheet class object pointer as the parent window when creating

CPropertyPage::Create(UINT nIDTemplate, CWnd* pParentWnd = NULL)

Then command in the menu

CPropertySheet *pParent = (CPropertySheet *)GetParent();

pParent->SetActivePage(iPage);

Second type

is to save the CPropertySheet object pointer in your CPropertyPage class. It is passed in when the CPropertyPage object is constructed, and then SetActivePage is directly passed through this pointer in the menu command message processing


The third method

is to save the window handle of the CPropertySheet object in your CPropertyPage class. Pass it in when the CPropertyPage object is constructed, and then use this handle to send the self-portrait to CPropertySheet in the menu command message processing. Define the message. When CPropertySheet receives this message, SetActivePage

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template