I have a class called Logger, which has an ObservableCollection which holds all of the item data that is bound to a ListView control on my MainWindow class.
Inside the Logger class I raise the PropertyChangedEventHandler event to tell the UI that the collection has been updated. At this point I would also like to update the UI to scroll the ListView to the bottom.
Where or how would I go about this? I was looking for an attribute of the XAML control like "OnPropertyChanged" and inside it I could do something to scroll to the bottom.
I know that from within a class that has an instance of the MainWindow I can simply use the ScrollIntoView method on the LV box, but since I don't have an instance of the Window in the Logger class, how can I achieve this?
Sorry if this is straightforward, I'm in the early stages of WPF!
Cheers, Dave