Share via


WizardForm.Pages Property

Definition

Gets the IList interface that contains the collection of pages in the wizard.

protected public:
 property System::Collections::IList ^ Pages { System::Collections::IList ^ get(); };
protected internal System.Collections.IList Pages { get; }
member this.Pages : System.Collections.IList
Protected Friend ReadOnly Property Pages As IList

Property Value

An IList interface that contains the list of pages in the wizard form.

Examples

The following example demonstrates the Pages property and displays the number of wizard pages. This code example is part of a larger example provided for the WizardForm class.

protected new IList Pages
{
    get
    {
        // Get a wizard page collection.
        WizardPage[] wizardPages = GetWizardPages();
        ShowMessage("There are " + wizardPages.Length + " wizard pages.");
        return wizardPages;
    }
}
protected new IList Pages
{
    get
    {
        // Get a wizard page collection.
        WizardPage[] wizardPages = GetWizardPages();
        ShowMessage("There are " + wizardPages.Length + " wizard pages.");
        return wizardPages;
    }
}

Remarks

Returning a collection of wizard pages enables you to handle, search, and sort the wizard pages.

The returned collection provides the functionality of the System.Collections.IList interface and exposes all the elements of the collection. The interface that the Pages property gets can be cast to any type that implements the System.Collections.IList interface.

This property enables you to create a custom Pages property.

Applies to

See also