Is there any way to convert Auto property to Notify Property automaticly?
INotifyPropertyChanged
Or any other way for MVVM in WPF
public string Filename { get; set; }
To
string _Filename;
public string Filename {
get { return _Filename; }
set {
if (PropertyChanged != null) {
_Filename = value;
PropertyChanged(this, new PropertyChangedEventArgs("Filename"));
}
}
}
There's a kindofmagic project that looks close to what you need.
It's an MSBuild task that processes your assemblies and adds PropertyChanged
calls to the properties decorated with some [Magic]
attribute. I've used it a bit and find extremely helpful.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With