beta.blog

Programming

WPF: CheckBox Binding not Two-Way (fix)

by on Mar.25, 2013, under Programming

My WPF checkbox did update when the datasource changed, however, my data source didn’t update when the checked state of my checkbox changed.

This was my old XAML code:

<CheckBox IsChecked="{Binding EnableDBBackup}" />

And this was added to make the binding work two-way:

<CheckBox IsChecked="{Binding EnableDBBackup, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" />

Worked like a charm afterwards. 🙂

Leave a Comment more...

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!