Share via


WizardForm.TaskCaptionBorderStyle Property

Definition

Gets or sets the border style for the task caption.

public:
 property System::Windows::Forms::BorderStyle TaskCaptionBorderStyle { System::Windows::Forms::BorderStyle get(); void set(System::Windows::Forms::BorderStyle value); };
public System.Windows.Forms.BorderStyle TaskCaptionBorderStyle { get; set; }
member this.TaskCaptionBorderStyle : System.Windows.Forms.BorderStyle with get, set
Public Property TaskCaptionBorderStyle As BorderStyle

Property Value

One of the BorderStyle values that represents the style of border to display for the form. The default is FixedSingle.

Exceptions

Examples

The following example demonstrates the TaskCaptionBorderStyle property. This example sets the value of the TaskCaptionBorderStyle property to System.Windows.Forms.BorderStyle.None. This code example is part of a larger example provided for the WizardForm class.

public DemoModuleWizardForm(IServiceProvider serviceProvider)
    : base(serviceProvider)
{
    InitializeComponent();
    // Upon initial load, the StartPageIndex page is loaded.
    // Get the Pages for this Form;
    int pageCount = Pages.Count;
    TaskCaptionBorderStyle = BorderStyle.None;
    StartTaskProgress();
}
public DemoModuleWizardForm(IServiceProvider serviceProvider)
    : base(serviceProvider)
{
    InitializeComponent();
    // Upon initial load, the StartPageIndex page is loaded.
    // Get the Pages for this Form;
    int pageCount = Pages.Count;
    TaskCaptionBorderStyle = BorderStyle.None;
    StartTaskProgress();
}

Remarks

The border style appears between the caption and the page. If you have a progress bar running, the progress bar will cover up the caption border.

You can set the value of this property to System.Windows.Forms.BorderStyle.None (no border) or System.Windows.Forms.BorderStyle.FixedSingle (a single-line border) only. Setting the value to System.Windows.Forms.BorderStyle.Fixed3D will throw an System.ArgumentOutOfRangeException exception.

Applies to