2
votes

I am trying to understand the MVVM pattern and I don't clearly get the responsibilities of VM and M. I am trying to work on an wpf example with a Person class (with firstName, lastName and dateOfBirth). I have created such a class in my Model folder. Now I want a collection (an ObservableCollection) of the Person class that I want to bind to my View. Where should I maintain this collection? In ViewModel or Model?

1

1 Answers

1
votes

Here is tutorial They created very similar program to yours. In MODEL you should have class Person and add persons to collection. In VIEWMODEL ICmmand etc. Read data from Model and push to View. In View just display data.