Click here to Skip to main content
15,920,111 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: DAAAHH! What does this error message means? Pin
Bill Wilson15-Nov-01 12:22
Bill Wilson15-Nov-01 12:22 
AnswerRe: DAAAHH! What does this error message means? Pin
Bill Wilson15-Nov-01 12:22
Bill Wilson15-Nov-01 12:22 
AnswerRe: DAAAHH! What does this error message means? Pin
Rick York16-Nov-01 18:50
mveRick York16-Nov-01 18:50 
GeneralProperty Pages question Pin
RobJones15-Nov-01 9:03
RobJones15-Nov-01 9:03 
GeneralRe: Property Pages question Pin
Bill Wilson15-Nov-01 12:30
Bill Wilson15-Nov-01 12:30 
GeneralRe: Property Pages question Pin
RobJones16-Nov-01 3:18
RobJones16-Nov-01 3:18 
GeneralRe: Property Pages question Pin
Frank Deo16-Nov-01 3:48
Frank Deo16-Nov-01 3:48 
GeneralRe: Property Pages question Pin
Bill Wilson16-Nov-01 7:15
Bill Wilson16-Nov-01 7:15 
Your right, the data held in the dialogs that make up the wizard are no longer accessible. You should have a class that represents the wizard itself. This is the object whose DoModal method is executed. It is still accessible:

Here is a sample from a project I worked on last year. The first listing is the Wizard class itself. It is derived from CPropertySheet. The dialogs it presents are CPropertyPage derived objects. These are stored as member variables in the CWizard object.

Each of the property pages can access the CWizard class (as a parent window). While this one has no actual data stored in it, it could have. In this project, I have the individual property pages store data in project wide globals, so I didn't need to retrieve data from the Wizard itself.

#if !defined(AFX_WIZARD_H__14E36E7B_5840_11D4_BD9F_00B0D0209426__INCLUDED_)
#define AFX_WIZARD_H__14E36E7B_5840_11D4_BD9F_00B0D0209426__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// Wizard.h : header file
//
#include "Welcomeppg.h"
#include "Detectionppg.h"
#include "ComponentSelectionPpg.h"
#include "ComponentInstallationPpg.h"
#include "installCompletePpg.h"
#include "verifyppg.h"

/////////////////////////////////////////////////////////////////////////////
// CWizard

class CWizard : public CPropertySheet
{
	DECLARE_DYNAMIC(CWizard)

// Construction
public:
	CWizard(UINT nIDCaption, CWnd* pParentWnd = NULL, UINT iSelectPage = 0);
	CWizard(LPCTSTR pszCaption, CWnd* pParentWnd = NULL, UINT iSelectPage = 0);

// Attributes
public:

// Operations
public:

	CWelcomePpg m_ppgWelcome;
	CDetectionPpg m_ppgDetection;
	CComponentSelectionPpg m_ppgComponentSelection;
	CComponentInstallationPpg m_ppgComponentInstallation;
	CInstallCompletePpg m_ppgInstallComplete;
	CVerifyPpg m_ppgVerify;

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CWizard)
	public:
	virtual BOOL OnInitDialog();
	virtual BOOL PreTranslateMessage(MSG* pMsg);
	//}}AFX_VIRTUAL

// Implementation
public:
	virtual ~CWizard();

	// Generated message map functions
protected:
	//{{AFX_MSG(CWizard)
	virtual void OnCancel();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_WIZARD_H__14E36E7B_5840_11D4_BD9F_00B0D0209426__INCLUDED_)

GeneralRe: Property Pages question Pin
RobJones16-Nov-01 11:12
RobJones16-Nov-01 11:12 
GeneralRe: Property Pages question Pin
RobJones16-Nov-01 11:52
RobJones16-Nov-01 11:52 
GeneralRe: Property Pages question Pin
Bill Wilson16-Nov-01 13:12
Bill Wilson16-Nov-01 13:12 
GeneralRe: Property Pages question Pin
RobJones16-Nov-01 13:15
RobJones16-Nov-01 13:15 
GeneralRAS events Pin
15-Nov-01 4:24
suss15-Nov-01 4:24 
GeneralRe: RAS events Pin
Masaaki Onishi15-Nov-01 17:07
Masaaki Onishi15-Nov-01 17:07 
GeneralOwner drawn button with drop-down menu Pin
Derek Lakin15-Nov-01 3:35
Derek Lakin15-Nov-01 3:35 
QuestionWhen to delete, and when to NULL? Pin
Chambers15-Nov-01 3:33
Chambers15-Nov-01 3:33 
AnswerRe: When to delete, and when to NULL? Pin
Nish Nishant15-Nov-01 3:50
sitebuilderNish Nishant15-Nov-01 3:50 
AnswerRe: When to delete, and when to NULL? Pin
Jon Sagara15-Nov-01 4:53
Jon Sagara15-Nov-01 4:53 
GeneralRe: When to delete, and when to NULL? Pin
Ray Kinsella15-Nov-01 6:02
Ray Kinsella15-Nov-01 6:02 
GeneralRe: When to delete, and when to NULL? Pin
Jon Sagara15-Nov-01 6:46
Jon Sagara15-Nov-01 6:46 
GeneralRe: When to delete, and when to NULL? Pin
Jim A. Johnson15-Nov-01 6:08
Jim A. Johnson15-Nov-01 6:08 
GeneralRe: When to delete, and when to NULL? Pin
Jon Sagara15-Nov-01 6:50
Jon Sagara15-Nov-01 6:50 
GeneralRe: When to delete, and when to NULL? Pin
Michael Dunn15-Nov-01 9:11
sitebuilderMichael Dunn15-Nov-01 9:11 
GeneralRe: When to delete, and when to NULL? Pin
Jon Sagara15-Nov-01 10:58
Jon Sagara15-Nov-01 10:58 
GeneralRe: When to delete, and when to NULL? Pin
Jim A. Johnson15-Nov-01 12:15
Jim A. Johnson15-Nov-01 12:15 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.