MESCIUS.ActiveReports.Core.Rdl Assembly / GrapeCity.ActiveReports.PageReportModel Namespace / Length Structure / CompareTo Method / CompareTo(Length) Method
An System.Object to compare with this instance.
Example

In This Topic
CompareTo(Length) Method
In This Topic
Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object.
Syntax
'Declaration
 
Public Overloads Function CompareTo( _
   ByVal other As Length _
) As Integer
 

Parameters

other
An System.Object to compare with this instance.

Return Value

An System.Int32 value indicating the relative order of the objects being compared.

Less than zero This instance is less than other.
Zero This instance is equal to other.
Greater than zero This instance is greater than other.
Example
var length1 = new Length("1in");
var length2 = new Length("2in");
int result = length1.CompareTo(length2); // -1
See Also