ESRI.ArcGIS.Mobile
GetNearestCoordinate(Coordinate,Coordinate,Int32,Int32,Double) Method
See Also  Send Feedback
ESRI.ArcGIS.Mobile.Geometries Namespace > Geometry Class > GetNearestCoordinate Method : GetNearestCoordinate(Coordinate,Coordinate,Int32,Int32,Double) Method

targetCoordinate
The input coordinate to compare to.
queryNearestCoordinate
Returns the nearest coordinate.
partIndex
Returns the part index where the nearest coordinate was found.
segmentIndex
Returns the segment index on the part where the nearest coordinate was found.
squareDistanceFound
Return the squared distance.
Finds a Vertex on the geometry that is closest to the target coordinate.

Syntax

Visual Basic (Declaration) 
Public Overloads Function GetNearestCoordinate( _
   ByVal targetCoordinate As Coordinate, _
   ByVal queryNearestCoordinate As Coordinate, _
   ByRef partIndex As Integer, _
   ByRef segmentIndex As Integer, _
   ByRef squareDistanceFound As Double _
) As Boolean
C# 
public bool GetNearestCoordinate( 
   Coordinate targetCoordinate,
   Coordinate queryNearestCoordinate,
   ref int partIndex,
   ref int segmentIndex,
   ref double squareDistanceFound
)

Parameters

targetCoordinate
The input coordinate to compare to.
queryNearestCoordinate
Returns the nearest coordinate.
partIndex
Returns the part index where the nearest coordinate was found.
segmentIndex
Returns the segment index on the part where the nearest coordinate was found.
squareDistanceFound
Return the squared distance.

Exceptions

ExceptionDescription
ArgumentNullExceptionNull coordinate.

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2013 All Rights Reserved.