September 2012
Intermediate to advanced
464 pages
10h 55m
English
So far we've seen data binding occur for a target property base on a single source property. Sometimes, however, a target property depends on changes of more than one source property. This is supported in WPF through multi binding. Let's see how it's done.
Make sure Visual Studio is up and running.
We'll create a simple color selector using a multi-binding.
CH06.MultiBindings.MainWindow.xaml. Add the following to the existing Grid:<Grid.RowDefinitions> <RowDefinition /> <RowDefinition Height="Auto" /> <RowDefinition Height="Auto" /> <RowDefinition Height="Auto" /> </Grid.RowDefinitions> <Rectangle Stroke="Black" StrokeThickness="1" Margin="4" > </Rectangle> ...
Read now
Unlock full access