Share via


WizardPage.CanShowHelp Property

Definition

When overridden in a derived class, gets a value indicating whether the ShowHelp() method is supported.

protected public:
 virtual property bool CanShowHelp { bool get(); };
protected internal virtual bool CanShowHelp { get; }
member this.CanShowHelp : bool
Protected Friend Overridable ReadOnly Property CanShowHelp As Boolean

Property Value

true if the user can view the Help file; otherwise, false.

Examples

The following example demonstrates the CanShowHelp property. In this example, the CanShowHelp property is set to true, which enables the ShowHelp method. This code example is part of a larger example provided for the WizardPage class.

// Customize the CanShowHelp method.
public new bool CanShowHelp
{
    get
    {
        return true;
    }
}
// Customize the ShowHelp method.
public new void ShowHelp()
{
    // Check to determine if the CanShowHelp will
    // allow help to be shown.
    if (CanShowHelp)
    {
        // Show the help file.
        Help.ShowHelp(this, "D:/minint/Microsoft.NET/framework/1033/admin.chm");
        // Alternatively, use the folllowing to navigate to Tech Net.
        //Help.ShowHelp(null, "http://www.technet.com");
    }
}

Remarks

Implementers should check this property in the ShowHelp method to ensure that the user can view the file.

Applies to

See also