Prevent item selection from changing when a new item added

2 posts, 0 answers
  1. Kris
    Kris avatar
    1 posts
    Member since:
    Jun 2011

    Posted 14 Aug 2012 Link to this post

    When using a bindinglist on a ListView datasource, everytime a new object is added to the List, the view will automatically select the new item. 

    What i would like is for the list to be updated but the selected item to stay where it is. How do prevent the default behaviour? 
  2. Stefan
    Stefan avatar
    2891 posts

    Posted 17 Aug 2012 Link to this post

    Hi Kris,

    Thank you for writing.

    RadListView uses RadListSource to store its items and the latter keeps track of the current item, thus the last added item is selected. You can easily deselect this item if you do not consider this functionality useful in your case:
    radListView1.SelectedItem = null;
    radListView1.CurrentItem = null;

    There is a feature request for this functionality. Feel free to add your vote for it here:

    I hope this helps.
    the Telerik team
    RadControls for WinForms Q2'12 release is now live! Check out what's new or download a free trial >>
  3. DevCraft R3 2016 release webinar banner
Back to Top