I have a question about setting vertical offset of scroll viewer in mvvm pattern. So my use case is like on a product list page, the user clicks the "load more" button at the bottom of the list, it gets more products from server and the page still has the same vertical offset when the user clicks "load more". I can get the vertical offset when the user clicks "load more", but I have problem with setting it after more products are retrieved from server. First I tried to bind the offset to a dependency property in view model, and update it in the view model. However, the system complains that the verticaloffset property of scrollviewer is readonly. I also tried to do it in the view. I want to invoke _scrollViewer.ScrollToVerticalOffset() when the listbox is updated. However, I couldn't find a event like Listbox_Updated in listbox. Any idea how should I do that? Thanks!
Fei