CCustomAppWiz::Next

HomeOverviewsHow Do IDetailsSample

Feature Only in Professional and Enterprise Editions   Creating a Custom AppWizard is supported only in Visual C++ Professional and Enterprise Editions. For more information, see Visual C++ Editions.

virtual CAppWizStepDlg* Next( CAppWizStepDlg* pDlg );

Return Value

A pointer to the next step.

If pDlg is NULL, your custom AppWizard should return a pointer to Step 1. This default action, provided by CUSTMWZ.AWX, occurs when the user clicks OK from the Projects tab of the New dialog box.

If pDlg is the last step, your custom AppWizard should return NULL. This default action, provided by CUSTMWZ.AWX, occurs if SetNumberOfSteps is called incorrectly or if your project is based on an existing project. In the first case, MFCAPWZ.DLL assumes that there are no more steps and displays the New Project Information dialog box. In the second case, no steps are required, and the code provided by CUSTMWZ.AWX for Next adds project- and class-name macros to the dictionary.

For more information on steps, see CAppWizStepDlg.

Parameters

pDlg

Pointer to the current step, or NULL if the custom AppWizard user has chosen the Create button from either the New Project Workspace or Insert Project dialog box.

Remarks

Next moves to the next step. AppWizard (MFCAPWZ.DLL) calls this function whenever a user chooses either Next or OK. The Next button is located on the main, outer dialog box that MFCAPWZ.DLL displays. The OK button is located on the Projects tab of the New dialog box. If there is no next step, Next is inactive. For more information on steps and a description of the two-dialog-box structure of AppWizard and custom AppWizards, see CAppWizStepDlg.

Before Next is called, MFCAPWZ.DLL calls the CAppWizStepDlg::OnDismiss member function of the currently displayed step. You override OnDismiss to transfer data from the step’s controls to the appropriate variables and to update the appropriate dictionary values. If your custom AppWizard’s call to OnDismiss returns FALSE, then the step remains active, and Next is not called.

See Also   CCustomAppWiz Overview, Class Members, The Dictionary, SetNumberOfSteps, CCustomAppWiz::Back, CAppWizStepDlg::OnDismiss