This is a migrated thread and some comments may be shown as answers.
ListView
1 Answer 12 Views
This is a migrated thread and some comments may be shown as answers.
A
Top achievements
Rank 1
A asked on 15 Jul 2016, 03:34 PM

Evaluating product;

 

How can I cancel a SelectedIndex change for a RadListView??

 

Thanks!

1 Answer, 1 is accepted

Sort by
0
Dimitar
Telerik team
answered on 18 Jul 2016, 10:10 AM
Hello ,

Thank you for writing.

You should be able to use the CurrentItemChanging event, however, it appears that there is an issue with the event and the item is changed event if the Cancel property is set to true. I have logged the issue in our Feedback Portal. You can track the item for status changes and add your vote for it here.

To workaround this you can use the SelectedIndexChanged event:
private void RadListView1_SelectedIndexChanged(object sender, EventArgs e)
{
    this.radListView1.SelectedIndexChanged -= RadListView1_SelectedIndexChanged;
    this.radListView1.SelectedIndex = 0;
    this.radListView1.SelectedIndexChanged += RadListView1_SelectedIndexChanged;
}

Your Telerik Points have been updated for this report.

Should you have any other questions do not hesitate to ask.
 
Regards,
Dimitar
Telerik by Progress
Check out the Windows Forms project converter, which aids the conversion process from standard Windows Forms applications written in C# or VB to Telerik UI for WinForms.For more information check out this blog post and share your thoughts.
Asked by
A
Top achievements
Rank 1
Answers by
Dimitar
Telerik team
Share this question
or