New to Telerik UI for WPFStart a free 30-day trial

Converts data member value to display value for the needs of lookup (ComboBox columns).

Definition

Namespace:Telerik.Windows.Controls

Assembly:Telerik.Windows.Controls.GridView.dll

Syntax:

C#
public class LookupValueConverter : IValueConverter

Inheritance: objectLookupValueConverter

Implements: IValueConverter

Constructors

Initializes a new instance of the LookupValueConverter class.

C#
public LookupValueConverter(GridViewComboBoxColumn column)
Parameters:columnGridViewComboBoxColumn

The column.

Methods

Converts the data member value to the display member value for the lookup column.

C#
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
Parameters:valueobject

The source data being passed to the target.

targetTypeType

The Type of data expected by the target dependency property.

parameterobject

The data model.

cultureCultureInfo

The culture of the conversion.

Returns:

object

The converted value to be displayed in the lookup column.

Converts the display member value to the data member value for the lookup column.

C#
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
Parameters:valueobject

The target data being passed to the source.

targetTypeType

The Type of data expected by the source object.

parameterobject

Contains the row data context.

cultureCultureInfo

The culture of the conversion.

Returns:

object

The value to be passed to the source object.