BindingBase::FallbackValue Property


The .NET API Reference documentation has a new home. Visit the .NET API Browser on to see the new experience.

Gets or sets the value to use when the binding is unable to return a value.

Namespace:   System.Windows.Data
Assembly:  PresentationFramework (in PresentationFramework.dll)

property Object^ FallbackValue {
	Object^ get();
	void set(Object^ value);

Property Value

Type: System::Object^

The default value is DependencyProperty::UnsetValue.

A binding returns a value successfully if:

  1. The path to the binding source resolves successfully.

  2. The value converter, if any, is able to convert the resulting value.

  3. The resulting value is valid for the binding target (target) property.

If 1 and 2 return DependencyProperty::UnsetValue, the target property is set to the value of the FallbackValue, if one is available. If there is no FallbackValue, the default value of the target property is used.

The value DependencyProperty::UnsetValue is not considered a successful return value.

<objectFallbackValue="fallbackValue" />

- or –



An attribute or object element value of the same type as the target property. See that type's documentation for XAML usage information. That type may or may not support attribute syntax for its values, or may or may not support object element syntax (which requires a default constructor on that type). The target property type will therefore influence which syntax you use for the value of the FallbackValue property.

.NET Framework
Available since 3.0
Available since 4.0
Windows Phone Silverlight
Available since 7.1
Return to top