compareEndPoints()

This method is used to compare the two end points (start and finish) of two ranges, the ranges being the current range and a range that has been previously stored as a variable. The first parameter defines the start and end point of each range being compared. If the result of the comparison of the two ranges finds that the first point of a range is earlier in the range than the other point, the value returned is -1. If the comparison shows that both points are at the same location, the returned value is 0. If the comparison shows that the first point is later in the range than the second point, the returned value is 1.

syntax:

compareEndPoints(type, range to be compared)

This method is used with the following:

textRange