tags:

views:

24

answers:

2

Let's say we have a text field named TXTBLAH and a setting named SETTINGBLAH

Is there anyway to write in XAML markup that whenever the text field BLAH gets updated to write that to the registry, and also when the form loads is there a XAML binding to restore it?

+1  A: 

I think that you'll find this link very helpful.

Property Changed Event

Ardman
haha I thought WPF was suppose to decouple the business logic from the UI and all that jazz... but they want us to stick WPF only events for UI logic into our business classes? >.< Code re-use has hit an all time low!
Jeff Dahmer
@Jeff. I thought so too at first, but you'll notice that `INotifyPropertyChanged` is not really a gui-only thing. It *is* used extensively for gui and databinding scenarios, but you *could* use it for other non-gui purposes. That's why you find the interface in the `System.ComponentModel` namespace.
Benny Jobigan