Export (0) Print
Expand All

Binding.ConverterParameter Property

Gets or sets a parameter that can be used in the Converter logic.

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

public Object ConverterParameter { get; set; }
<Binding ConverterParameter="parameter"/>
-or-
<Binding ConverterParameter="parameterReference"/>

XAML Values

parameter

A parameter value that is either a primitive value, or can be type converted from a string.

parameterReference

A parameter value that is obtained as a reference to an already existing object. Typically the object is created in a ResourceDictionary and given a key, then referenced by using the StaticResource markup extension.

Property Value

Type: System.Object
A parameter to be passed to the Converter. This can be used in the conversion logic. The default is null.

ExceptionCondition
InvalidOperationException

The Binding has already been attached to a target element, and cannot be modified.

XAML Usage Notes

ConverterParameter can be set as a binding property through the Binding markup extension, which enables specifying an entire Binding as an attribute string. For more information, see Binding Markup Extension.

Property element syntax to create an object element that fills a Binding.ConverterParameter property element is possible, but uncommon.

Silverlight

Supported in: 5, 4, 3

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1, Windows Phone OS 7.0

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Community Additions

ADD
Show:
© 2014 Microsoft