HeaderPane
Main
Hide
Share Link
Print

Add Method, SftTaskDialogRadioButtonCollection Class

Adds a new radio button with the specified text.

Class: SftTaskDialogRadioButtonCollection
Namespace: Softelvdm.SftStyleNET
Assembly: Softelvdm.SftStyleNET

Syntax

public SftTaskDialogRadioButton Add( string text );
Public Function Add( ByVal text As String ) As SftTaskDialogRadioButton

Parameters

text

The text of the radio button.

Return Value

The new radio button.

Comments

Adds a new radio button with the specified text.

Examples

C# View entire sample code

            SftTaskDialogPage page = new SftTaskDialogPage {
                Caption = "Export",
                Heading = "Choose the export format",
                Text = "The report covers 1,284 orders. Read the <a href=\"formats\">format notes</a> first.",
                EnableLinks = true,
                Verification = new SftTaskDialogVerificationCheckBox("&Open the file after the export"),
                Expander = new SftTaskDialogExpander("Comma-separated files open in any spreadsheet program; PDF keeps the layout of the report."),
            };
            page.RadioButtons.Add("&Comma-separated values (.csv)").Checked = true;
            page.RadioButtons.Add("&PDF document");
            SftTaskDialogButton apply = new SftTaskDialogButton("&Apply") { AllowCloseDialog = false };
            page.Buttons.Add(apply);
            page.Buttons.Add(SftTaskDialogButton.OK);
            page.Buttons.Add(SftTaskDialogButton.Cancel);
            page.Buttons.Add(SftTaskDialogButton.Help);

VB.NET View entire sample code

    Private Sub ButtonTaskDialog_Click(ByVal sender As Object, ByVal e As EventArgs) Handles ButtonTaskDialog.Click
        Dim page As New SftTaskDialogPage()
        page.Caption = "Export"
        page.Heading = "Choose the export format"
        page.Text = "The report covers 1,284 orders. Read the <a href=""formats"">format notes</a> first."
        page.EnableLinks = True
        page.Verification = New SftTaskDialogVerificationCheckBox("&Open the file after the export")
        page.Expander = New SftTaskDialogExpander("Comma-separated files open in any spreadsheet program; PDF keeps the layout of the report.")
        page.RadioButtons.Add("&Comma-separated values (.csv)").Checked = True
        page.RadioButtons.Add("&PDF document")
        Dim apply As New SftTaskDialogButton("&Apply")
        apply.AllowCloseDialog = False
        page.Buttons.Add(apply)
        page.Buttons.Add(SftTaskDialogButton.OK)
        page.Buttons.Add(SftTaskDialogButton.Cancel)
        page.Buttons.Add(SftTaskDialogButton.Help)

See Also SftTaskDialogRadioButtonCollection Class | Classes | SftStyle/NET 3.0