c# - Binding issue - Value not updating on View -


What am I trying to achieve, when the check box is checked, the text box will appear when If the checkbox is unchecked, the text box will display false.

At this time this issue works in the beginning, the box will be checked, and the text box will display the truth but when I uncheck it, the text box is telling the truth.

Sorry, if I'm missing something simple, still trying to understand Wpf and c #.

Thank you for helping.

>

XML:

  & lt; Grid & gt; & Lt; Checkbox content = "check me" horizontal alignment = "left" height = "19" margin = "88,63,0,0" vertical alignment = "top" width = "86" ischicode = "{binding currentview, mode = diva} "/> & Lt; TextBlock Text = "{binding currentview, mode = two}" horizontal alignment = "left" height = "39" margin = "88,82,0,0" textwiping = "wrap" vertical alignment = "top" width = "86" /> & Lt; / Grid & gt;  

Main window:

  Public partial square main window: window {public MainWindow () {InitializeComponent (); this. Datacontax = new main view (); }}  

Main view:

  Public square Main view: INotifyPropertyChanged {Private bool currentValue = true; Public Event Threaded ChangedEventHandler Property changed; Public Bull Currentview {Get {current current value}} set {if (currentValue == value) {return; } CurrentValue = Value; RaisePropertyChange ("Check_Value"); }} Protected Zero RisePropertyChange (string propertyName) {If (PropertyChanged! = Null) {PropertyChanged (New, PropertyChangedEventArgs (propertyName)); You are misrepresenting your property so that you can decide how to correct it  
  Public Bull CurrentView {Get {current currentvalue; } Set {if (currentValue! = Value) {currentValue = value; RaisePropertyChange ("CurrentValue"); }}}  

Comments