I work with a project on WPF, the interaction (communication) between View and ViewModel is performed via catel. Each xxxView.xaml representation corresponds to the xxxViewModel.cs model, but it turns out that there are single-type views in which only the names and values of the parameters change (markup by template).
Is it possible to change the data in one template (window call) in one template (we now have 15 pages of the same type with different keys for headers)
catelat this initial stage. As in your case there is a substitution; you do not study the underlying principles and general ways of implementing MVVM, but study a specific implementation, how it is done in this or the framework. As a result, you will "swim" and poorly understand how and what works and why it is done this way and not otherwise.xxxViewModel.cs- this is not a model file, but a view model. - BulsonMainViewModel, in it you need to create properties for all the necessary controls from MainWindow, with which you will work with data from the database. Bind together the view model and the window (for this is theDataContext), then bind in the controls to the properties of the view model. Search the Internet for a ready implementation ofRelayCommand, copy it to your project and use it to implement the commands for the buttons. In the constructor of the view model or on command, load data from the database into the model classes and forward. - Bulson