RadListView not scrolling to pre-selected item

2 posts, 0 answers
  1. Curtis
    Curtis avatar
    25 posts
    Member since:
    Oct 2014

    Posted 24 Jul Link to this post

    This is probably just me not knowing how to make this control do this but...

    I have a list of items and in-code I'm selecting an item that off-screen but RadListView doesn't auto-scroll to that item.  it IS selected just not in view.

    Do I have to do something like:  radListView1.ShowSelectedItem(someRadListDataItem)

    or perhaps from the item itself?  Something that works like this:  someRadListDataItem.EnsureVisible = True

    ??

     

    Any help would be appreciated.

    -c

  2. Petar Mladenov
    Admin
    Petar Mladenov avatar
    2986 posts

    Posted 26 Jul Link to this post

    Hello Curtis,

    You can use the following methods:

    this.radListBox.ScrollIntoView(this.radListBox.SelectedItem);
     
    this.radListBox.ScrollIntoView(this.radListBox.SelectedIndex);


    Regards,
    Petar Mladenov
    Progress Telerik
    Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
Back to Top