RadTreeViewItem.get_nextitem()

2 posts, 0 answers
  1. Sebastian
    Sebastian avatar
    7 posts
    Member since:
    Mar 2011

    Posted 21 Nov 2011 Link to this post

    Hello,

    i have a problem with a RadTreeView i do not know how to deal with.

    I have a TreeView with a HierarchicalDataTemplate.
    I poulate the tree by assigning a List<myClass> to its ItemSource.
    SelectedItem is set at start and then in SelectionChanged eventhandler.

    Everythign works as it is expected, unless i try to navifate not by Mouse but Keyboard.
    KeyDown and KeyUp result in the following error:

    bei Telerik.Windows.Controls.RadTreeViewItem.get_PreviousItem()
     
    bei Telerik.Windows.Controls.RadTreeView.HandleUpArrowKey(KeyEventArgs e)
     
    bei Telerik.Windows.Controls.RadTreeView.HandleKeyDown(KeyEventArgs e)
     
    bei Telerik.Windows.Controls.RadTreeViewItem.OnKeyDown(KeyEventArgs e)
     
    bei System.Windows.Controls.Control.OnKeyDown(Control ctrl, EventArgs e)
     
    bei MS.Internal.JoltHelper.FireEvent(IntPtr unmanagedObj, IntPtr unmanagedObjArgs, Int32 argsTypeIndex, Int32 actualArgsTypeIndex, String eventName)
    repectively get_NextItem() in the first line.

    what can i do to avoid that?
    This happens in all TreeViews that are populated that way, as far as i can see.

    Regards
    Seb
  2. Petar Mladenov
    Admin
    Petar Mladenov avatar
    2891 posts

    Posted 24 Nov 2011 Link to this post

    Hello Sebastian,

     We are not aware of such existing issue in the RadTreeView and we were also unable to reproduce it. Could you please check out our test project, modify it if needed or let us know if we are missing something ? You can also send us a runnable sample so that we could investigate it better and provide you a solution or workaround.
    On a side note, we highly suggest you to use ObservableCollection<> instead of List<> when you bind your RadTreeView. This is mandatory if you want to perform Drag/Drop operations for example.

    Best wishes,
    Petar Mladenov
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  3. DevCraft banner
Back to Top