I study WPF and, accordingly, MVVM pattern.
Now I am writing a program as a workout. The program takes data from a user-selected file, converts it and outputs it to a DataTable . To clear the DataTable I assign the property to which the ItemsSource table is attached, null and call OnPropertyChanged .
So the question is, is it possible to frequently call this method, how will it affect performance? For example, I have 5 different tables and when processing each file they need to be cleared from the results of the previous file. As I said, I clear by assigning a null property.
Maybe there is another way to update the contents of DataTable ( taking into account the MVVM pattern )?