In This Article

DoubleMaximumConverter Class

Represents a value converter that returns the maximum of the values that are passed to the converter.

[ValueConversion(typeof(double), typeof(double))]
public class DoubleMaximumConverter : DependencyObject
Inheritance:
object object

Constructors

DoubleMaximumConverter()

Initializes an instance of the class.

public DoubleMaximumConverter()

Properties

ValueCount

Gets or sets the number of values used to calculate the maximum. This is a dependency property.

public int ValueCount { get; set; }

Property Value

int:

The number of values to use to calculate the maximum, or -1 for no limit.

Methods

Convert(object, Type, object, CultureInfo)

Converts the specified value to the maximum value based on the previous values converted.

public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
Parameter Type Description
value object

The value produced by the binding source.

targetType Type

The type of the binding target property.

parameter object

The converter parameter to use.

culture CultureInfo

The culture to use in the converter.

Returns

object:

The maximum value of the specified value and previous values.

ConvertBack(object, Type, object, CultureInfo)

This method always throws a NotImplementedException exception and should not be used.

public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
Parameter Type Description
value object

Not used.

targetType Type

Not used.

parameter object

Not used.

culture CultureInfo

Not used.

Returns

object

Fields

ValueCountProperty

Identifies the ValueCount dependency property. This field is read-only.

public static readonly DependencyProperty ValueCountProperty