Pergunta

How can I limit the number of selected (checked) items in a radTreeListView? Say after a user has selected (checked) 5 items, a stop them from checking/selecting more items in c#.

Which event to I need to handle?

Foi útil?

Solução

Achivement:

 private void radTreeListView_SelectionChanging(object sender, Telerik.Windows.Controls.SelectionChangingEventArgs e)
    {
        if (radTreeListView.SelectedItems.Count >= 5 && e.AddedItems.Count>0)
            e.Cancel = true;
    }
Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top