Hello.
I have a main ViewModel that loads two seperate child viewmodels. like so:
-
-
-
- public MVVM.ViewModelBase ViewModel
- {
- get { return viewModel; }
- set
- {
- viewModel = value;
- RaisePropertyChanged("ViewModel");
- }
- }
- MVVM.ViewModelBase viewModel;
-
- public UsersViewModel()
- {
- this.ViewModel = new UsersListViewModel();
- }
-
-
-
-
- void addUserExecute()
- {
- ViewModel = new UsersEditViewModel(-1);
- }
- bool canAddUserExecute()
- {
- return true;
- }
- public ICommand AddUser { get { return new MVVM.RelayCommand(addUserExecute, canAddUserExecute); } }
I can't seem to figure out how to let my child (UsersEditViewModel) to tell the parent that i'm done editing and need to close/dispose.
Any help would be greatly appreciated.