data binding - WPF: refreshing a control with a bound property using Model View View-Model -


I am using a model view view-model pattern for a WPF app. I have a view modal with two properties (set as pages), one of which is a unit with a property-changed event. In the event handler, I have set the value of other assets (bullion) for some value.

Now the buttons and text box properties are imposing penalty on first load and firing and talking about the incident-altered event, however, the update of the button's insensable property to display changes in its bound property Does not.

ViewModel looks like this:

  Public Seal Class CustomerPageViewModel {PUBLIC CUSTOMER CUSTOMER {Receive; Set; } Public Bull Editing {get; Private set; } Private Zero customer_procedChanged (Object Sender, System.ComponentModel.PropertyChangedEventArgs e) {edit = true; }}  

and the xaml sorta looks like this:

  & lt; Text box text = "{customer bond .names}" /> & Lt; Button Content = "Save Changes" isEnabled = "{Binding Editing}" />  

When I change the underlying property in ViewModel, how can I get the button to update my insensible property?

Is this your real code for the viewload? If so, then your problem is that your viewhold does not apply to INOTifyPropertyChanged. WPF can not know that your "editing" VM property has changed, so that button is not binding.


Comments

Popular posts from this blog

c++ - Linux and clipboard -

Visual Studio 2005: How to speed up builds when a VSMDI is open? -

booting ubuntu from usb using virtualbox -