Converter. Convert(Object, Type, Object, CultureInfo) Method
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Converts a value.
public: System::Object ^ Convert(System::Object ^ value, Type ^ targetType, System::Object ^ parameter, System::Globalization::CultureInfo ^ culture);
public object Convert (object value, Type targetType, object parameter, System.Globalization.CultureInfo culture);
abstract member Convert : obj * Type * obj * System.Globalization.CultureInfo -> obj
Public Function Convert (value As Object, targetType As Type, parameter As Object, culture As CultureInfo) As Object
The value produced by the binding source.
The type of the binding target property.
The converter parameter to use.
The culture to use in the converter.
A converted value. If the method returns
null, the valid null value is used.
The data binding engine calls this method when it propagates a value from the binding source to the binding target.
The data binding engine does not catch exceptions that are thrown by a user-supplied converter. Any exception that is thrown by the Convert method, or any uncaught exceptions that are thrown by methods that the Convert method calls, are treated as run-time errors. Handle anticipated problems by returning DependencyProperty.UnsetValue.