Hello, Thanks for reply,
For example, we have two modules and each module a viewmodel we now how to share viewmodels if clicked save button all property save to xml format.
Modules1
For example, we have two modules and each module a viewmodel we now how to share viewmodels if clicked save button all property save to xml format.
Modules1
namespace Modules.VM1.ViewModels
{
[Export]
[PartCreationPolicy(CreationPolicy.Shared)]
public class VM1ViewModel : Infrastructure.ViewModels.NavigationAwareDataViewModel
{
[ImportingConstructor]
public VM1ViewModel()
{
}
private bool _isCheckBox;
public bool IsCheckBox
{
get { return _isCheckBox; }
set
{
_isCheckBox= value;
this.RaisePropertyChanged(() => IsCheckBox);
}
}
}
Modules2namespace Modules.VM2.ViewModels
{
[Export]
[PartCreationPolicy(CreationPolicy.Shared)]
public class VM2ViewModel : Infrastructure.ViewModels.NavigationAwareDataViewModel
{
[ImportingConstructor]
public VM2ViewModel()
{
}
private bool _isRadioButton;
public bool IsRadioButton
{
get { return _isRadioButton; }
set
{
_isRadioButton= value;
this.RaisePropertyChanged(() => IsRadioButton);
}
}
}