Binding Modes

Apart from the default binding, which is one-way, you can also configure binding to be two-way, one-way to source, and so forth. You can do this by specifying the Mode property, as shown in Table 8-1.

Table 8-1. Binding Modes

Mode

Description

OneWay

This causes changes to the source property to automatically update the target property but the source does not get changed.

TwoWay

This causes changes in the source or target to automatically update the other.

OneWayToSource

This causes changes to the target property to automatically update the source property but the target does not get changed.

OneTime

This causes only the first-time change to the source property to automatically update the target property but the source does not get changed, ...

Get XAML Developer Reference now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.