Share via


ProjectPropertyComparator.Compare method (DateTime, DateTime)

Compares two DateTime values to identify their relative positions in the sort order.

Namespace:  Microsoft.Office.Project.Server.Library
Assembly:  Microsoft.Office.Project.Server.Library (in Microsoft.Office.Project.Server.Library.dll)

Syntax

'Declaration
Public Shared Function Compare ( _
    prop1 As DateTime, _
    prop2 As DateTime _
) As Integer
'Usage
Dim prop1 As DateTime
Dim prop2 As DateTime
Dim returnValue As Integer

returnValue = ProjectPropertyComparator.Compare(prop1, _
    prop2)
public static int Compare(
    DateTime prop1,
    DateTime prop2
)

Parameters

Return value

Type: System.Int32
Returns "-1" if the first date is earlier than the second, returns "1" if the first date is later than the second , or returns "0" if they are the same date.

See also

Reference

ProjectPropertyComparator class

ProjectPropertyComparator members

Compare overload

Microsoft.Office.Project.Server.Library namespace