In This Article

WizardDialogForm Class

Provides an implementation of a Form with a Wizard control filling its client area.

public class WizardDialogForm : DpiAwareForm, IDpiAwareElement
Inheritance:
Object DpiAwareForm Object
Implements:
IDpiAwareElement

Remarks

To create a custom wizard dialog, create a Form that inherits from the WizardDialogForm. Then set the properties of the Wizard control and override the protected On... methods of the WizardDialogForm.

Constructors

WizardDialogForm()

Initializes a new instance of the WizardDialogForm class.

public WizardDialogForm()

Remarks

The default constructor initializes all fields to their default values.

Properties

Text

Gets the text that is displayed in the title bar of the Form.

public override string Text { get; set; }

Property Value

String:

The text that is displayed in the title bar of the Form.

Remarks

This property returns the title bar text as constructed by the TitleStyle.

TitleBarText

Gets or sets the base text to be displayed in the title bar of the Form.

public string TitleBarText { get; set; }

Property Value

String:

The base text to be displayed in the title bar of the Form.

Remarks

The TitleStyle property specifies how to modify this text for display in the title bar.

TitleStyle

Gets or sets how to modify the text in the title bar of the Form.

public WizardDialogTitleStyle TitleStyle { get; set; }

Property Value

WizardDialogTitleStyle:

A WizardDialogTitleStyle specifying how to modify the text in the title bar of the Form.

Methods

Dispose(Boolean)

Clean up any resources being used.

protected override void Dispose(bool disposing)
Parameter Type Description
disposing Boolean

OnBackButtonClick(WizardPageCancelEventArgs)

Occurs when Back button on the Wizard is clicked.

protected virtual void OnBackButtonClick(WizardPageCancelEventArgs e)
Parameter Type Description
e WizardPageCancelEventArgs

A WizardPageCancelEventArgs that contains the event data.

Remarks

By default, the Wizard will move to the previous WizardPage in the WizardPageCollection after this event fires. To cancel this behavior, set the Cancel property of the event argument to true. Then you can use the SelectedIndex property to set the WizardPage that should be displayed.

If the selected page has an event handler for this event, this particular event will not be raised since it will be assumed that the associated page's event handler executed the appropriate code.

OnCancelButtonClick(EventArgs)

Occurs when Cancel button on the Wizard is clicked.

protected virtual void OnCancelButtonClick(EventArgs e)
Parameter Type Description
e EventArgs

An EventArgs that contains the event data.

OnFinishButtonClick(EventArgs)

Occurs when Finish button on the Wizard is clicked.

protected virtual void OnFinishButtonClick(EventArgs e)
Parameter Type Description
e EventArgs

An EventArgs that contains the event data.

OnHelpButtonClick(EventArgs)

Occurs when Help button on the Wizard is clicked.

protected virtual void OnHelpButtonClick(EventArgs e)
Parameter Type Description
e EventArgs

An EventArgs that contains the event data.

OnLayoutButtons(WizardLayoutButtonsEventArgs)

Occurs when control is requested to lay out it's child controls.

protected virtual void OnLayoutButtons(WizardLayoutButtonsEventArgs e)
Parameter Type Description
e WizardLayoutButtonsEventArgs

A WizardLayoutButtonsEventArgs that contains the event data.

OnNextButtonClick(WizardPageCancelEventArgs)

Occurs when Next button on the Wizard is clicked.

protected virtual void OnNextButtonClick(WizardPageCancelEventArgs e)
Parameter Type Description
e WizardPageCancelEventArgs

A WizardPageCancelEventArgs that contains the event data.

Remarks

By default, the Wizard will move to the next WizardPage in the WizardPageCollection after this event fires. To cancel this behavior, set the Cancel property of the event argument to true. Then you can use the SelectedIndex property to set the WizardPage that should be displayed.

If the selected page has an event handler for this event, this particular event will not be raised since it will be assumed that the associated page's event handler executed the appropriate code.

OnSelectionChanged(EventArgs)

Occurs after a page is selected.

protected virtual void OnSelectionChanged(EventArgs e)
Parameter Type Description
e EventArgs

An EventArgs that contains the event data.

OnSelectionChanging(WizardPageCancelEventArgs)

Occurs before a page is selected.

protected virtual void OnSelectionChanging(WizardPageCancelEventArgs e)
Parameter Type Description
e WizardPageCancelEventArgs

A WizardPageCancelEventArgs that contains the event data.

OnUpdateTitleBarText(WizardDialogTitleBarTextEventArgs)

Occurs when the title bar text of the WizardDialogForm needs to be updated.

protected virtual void OnUpdateTitleBarText(WizardDialogTitleBarTextEventArgs e)
Parameter Type Description
e WizardDialogTitleBarTextEventArgs

A WizardDialogTitleBarTextEventArgs that contains the event data.

UpdateTitleBarText()

Updates the title bar text.

public void UpdateTitleBarText()

Fields

Wizard

Gets the Wizard control that is contained by the WizardDialogForm.

protected Wizard Wizard

Inherited Members