Skip to main content

ListBoxSelectionMode Enum

Lists the values that specify the selection behavior for a list editor.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v24.1.dll

NuGet Package: DevExpress.Blazor

Declaration

public enum ListBoxSelectionMode

Members

Name Description
Single

Users can only select one List Box item at once.

Multiple

Users can select multiple items in List Box.

None

Users cannot select items in List Box.

Related API Members

The following properties accept/return ListBoxSelectionMode values:

Remarks

<DxListBox Data="@Staff.DataSource"
           TextFieldName="@nameof(Person.Text)"
           SelectionMode="ListBoxSelectionMode.Multiple"
           ShowCheckboxes="@ShowCheckboxes"
           @bind-Values="@Values">
</DxListBox>

@code {
    IEnumerable<Person> values = Staff.DataSource.Take(2);
    IEnumerable<Person> Values {
        get => values;
        set { values = value; InvokeAsync(StateHasChanged); }
    }

    bool showCheckboxes = true;
    bool ShowCheckboxes {
        get => showCheckboxes;
       set { showCheckboxes = value; InvokeAsync(StateHasChanged); }
    }
}

ListBox Multiple Selection

Run Demo: List Box - Multiple Selection

See Also