New to Telerik UI for BlazorStart a free 30-day trial

Read-Only ListBox

Updated on Mar 25, 2026

Environment

ProductListBox for Blazor

Description

I want to make the ListBox read-only. I am looking for a solution that doesn't allow users to modify the selected items or interact with the toolbar.

Solution

To achieve a read-only effect in the TelerikListBox, follow these steps:

  1. Use one-way binding for the SelectedItems parameter of the component.
  2. Define a SelectedItemsChanged event handler, but avoid updating the SelectedItems parameter in the handler.
  3. Hide the ListBox toolbar by setting the Visible property of the ListBoxToolBar to false.

Here is an example:

<TelerikListBox Data="@ListBoxStrings"
                SelectedItems="@ListBoxSelectedStrings"
                SelectedItemsChanged="@((IEnumerable<string> list) => ListBoxSelectedStringsHandler(list))"
                Height="auto">
    <ListBoxToolBarSettings>
        <ListBoxToolBar Visible="false" />
    </ListBoxToolBarSettings>
</TelerikListBox>

@code {
    private List<string> ListBoxStrings { get; set; } = new List<string>();
    private IEnumerable<string> ListBoxSelectedStrings { get; set; } = new List<string>();

    private void ListBoxSelectedStringsHandler(IEnumerable<string> list)
    {
        // You can execute custom logic here, but do not update ListBoxSelectedStrings
        // to prevent the user from changing the selection.
    }

    protected override void OnInitialized()
    {
        for (int i = 1; i <= 7; i++)
        {
            ListBoxStrings.Add($"String {i}");
        }

        ListBoxSelectedStrings = new List<string> { "String 2", "String 5" };
    }
}

See Also