WPF Databinding CheckBox.IsChecked

后端 未结 4 420
甜味超标
甜味超标 2020-12-18 01:20

How would I bind the IsChecked member of a CheckBox to a member variable in my form?

(I realize I can access it directly, but I am trying to learn about databinding

4条回答
  •  不思量自难忘°
    2020-12-18 01:27

    
      
        
      
    
    

    Note i added a name to , and changed the binding in your CheckBox. You will need to implement ShowPending as a DependencyProperty as well if you want it to be able to update when changed.

提交回复
热议问题