Back to Devexpress

SortArgs.SecondValue Property

corelibraries-devexpress-dot-mvvm-dot-xpf-dot-sortargs-be7e5b0f.md

latest3.3 KB
Original Source

SortArgs.SecondValue Property

Gets the second compared value.

Namespace : DevExpress.Mvvm.Xpf

Assembly : DevExpress.Mvvm.v25.2.dll

NuGet Packages : DevExpress.Mvvm, DevExpress.Win.Navigation

Declaration

csharp
public object SecondValue { get; }
vb
Public ReadOnly Property SecondValue As Object

Property Value

TypeDescription
Object

The second compared value.

|

The following code snippets (auto-collected from DevExpress Examples) contain references to the SecondValue property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

wpf-data-grid-implement-custom-grouping/CS/CustomGrouping_MVVM/MainViewModel.cs#L38

csharp
double x = Math.Floor(Convert.ToDouble(args.FirstValue) / 10);
double y = Math.Floor(Convert.ToDouble(args.SecondValue) / 10);
args.Result = x > 9 && y > 9 ? 0 : x.CompareTo(y);

wpf-data-grid-implement-custom-sorting/CS/CustomSorting_MVVM/MainViewModel.cs#L36

csharp
int dayIndex1 = GetDayIndex(args.FirstValue);
int dayIndex2 = GetDayIndex(args.SecondValue);
args.Result = dayIndex1.CompareTo(dayIndex2);

wpf-data-grid-implement-custom-grouping/VB/CustomGrouping_MVVM/MainViewModel.vb#L46

vb
Dim x As Double = Math.Floor(Convert.ToDouble(args.FirstValue) / 10)
Dim y As Double = Math.Floor(Convert.ToDouble(args.SecondValue) / 10)
args.Result = If(x > 9 AndAlso y > 9, 0, x.CompareTo(y))

wpf-data-grid-implement-custom-sorting/VB/CustomSorting_MVVM/MainViewModel.vb#L44

vb
Dim dayIndex1 As Integer = Me.GetDayIndex(args.FirstValue)
Dim dayIndex2 As Integer = Me.GetDayIndex(args.SecondValue)
args.Result = dayIndex1.CompareTo(dayIndex2)

See Also

SortArgs Class

SortArgs Members

DevExpress.Mvvm.Xpf Namespace