I have a tree view that displays a structure of agenda items. The tree structure is merely for ui and usability purposes. The tree view is “flattened” into a linear list of agenda items. When an item is selected in the tree view, I would like to scroll the corresponding linear list item to the top of the listview. The items in the listview are custom user controls. I would like to use an attached behavior since I need to stay within MVVM. I have manly to issues. I need to be able to inject an index into the view and trigger the scroll itself by a command. Any ideas? Kind regards
This approach seem feasible but Im not getting how to pass an index to a behavior. https://marcominerva.wordpress.com/2014/09/30/scrolltobottom-behavior-for-listview-in-mvvm-based-universal-windows-apps/