RelativeSource.Mode Property
.NET Framework (current version)
Gets or sets a RelativeSourceMode value that describes the location of the binding source relative to the position of the binding target.
Assembly: PresentationFramework (in PresentationFramework.dll)
Property Value
Type: System.Windows.Data.RelativeSourceModeOne of the RelativeSourceMode values. The default value is null.
| Exception | Condition |
|---|---|
| InvalidOperationException | This property is immutable after initialization. Instead of changing the Mode on this instance, create a new RelativeSource or use a different static instance. |
This property is read-only after initialization. If this property is not set explicitly, setting the AncestorType or the AncestorType and the AncestorLevel properties will implicitly lock this property value to FindAncestor.
For XAML information, see RelativeSource MarkupExtension.
.NET Framework
Available since 3.0
Silverlight
Available since 3.0
Windows Phone Silverlight
Available since 7.0
Available since 3.0
Silverlight
Available since 3.0
Windows Phone Silverlight
Available since 7.0
Show: