Clear Selected Items

6 posts, 0 answers
  1. erwin
    erwin avatar
    358 posts
    Member since:
    Dec 2006

    Posted 17 Sep 2010 Link to this post

    What's the equivalent of

    RadListBox.SelectedItems.Clear()

    with the new control?
  2. Peter
    Admin
    Peter avatar
    1148 posts

    Posted 23 Sep 2010 Link to this post

    Hello erwin,

    Thanks for the writing.

    You should use: SelectRange(startIndex, endIndex) method. This method clears the currently selected items and selects all items in the closed range [startIndex, endIndex].

    Please refer to the code snippet below:

    radListControl1.SelectRange(-1, -1);

    Do not hesitate to contact us if you have other questions.

    Regards,
    Peter
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. UI for WinForms is Visual Studio 2017 Ready
  4. erwin
    erwin avatar
    358 posts
    Member since:
    Dec 2006

    Posted 23 Sep 2010 Link to this post

    Thanks Peter,

    IMHO not very intuitive / self documenting compared to

    SelectedItems.Clear()

    how about a ClearSelected() Method ?

    Regards
    Erwin
  5. Peter
    Admin
    Peter avatar
    1148 posts

    Posted 24 Sep 2010 Link to this post

    Hi erwin,

    Thank you for your suggestion.
    We will consider adding such a property, because SelectRange seems a bit unnatural. Probably the property will be available in the next official release.

    Don't hesitate to contact us if you have other questions.

    Regards,
    Peter
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  6. Yaroslav
    Yaroslav avatar
    24 posts
    Member since:
    Nov 2011

    Posted 14 Nov 2011 Link to this post

    Same suggestion as Erwin, the SelectRange is not intuitive, I spend about an hour before finding this post.

    ClearSelected() as before is more natural
  7. Peter
    Admin
    Peter avatar
    1148 posts

    Posted 17 Nov 2011 Link to this post

    Hi Yaroslav,

    Thank you for sharing your suggestion.

    As I said before, we will add a new method - ClearSelected.
    For the time being, as a workaround you should use SelectRange.

    Let me know if I can be of further assistance.

    All the best,
    Peter
    the Telerik team

    Q2’11 SP1 of RadControls for WinForms is available for download (see what's new); also available is the Q3'11 Roadmap for Telerik Windows Forms controls.

Back to Top
UI for WinForms is Visual Studio 2017 Ready