returns the index of the shape containing Point pt

Namespace:  EGIS.ShapeFileLib
Assembly:  EGIS.ShapeFileLib (in EGIS.ShapeFileLib.dll)

Syntax

Visual Basic (Declaration)
Public Function GetShapeIndexContainingPoint ( _
	pt As PointF, _
	minDistance As Single _
) As Integer
C#
public int GetShapeIndexContainingPoint(
	PointF pt,
	float minDistance
)
Visual C++
public:
int GetShapeIndexContainingPoint(
	PointF pt, 
	float minDistance
)

Parameters

pt
Type: System.Drawing..::.PointF
The location of the point
minDistance
Type: System..::.Single
the min distance (in ShapeFile coordinates) between pt and a shape when searching point or line shapes that will return a "hit".

Return Value

zero based index of the shape containing pt or -1 if no shape contains the point

Remarks

When searching in a Point ShapeFile a point will be defined as contining pt if the distance between the found point and pt is less than or equal to minDistance

When searching in a PolyLine ShapeFile a Line will be defined as containing the point if the distance between a line segment in the found shape and pt is less than or equal to minDistance

See Also