Partager via


Stroke.NearestPoint Method

Stroke.NearestPoint Method

Returns the location on the Stroke object nearest to a specified Point Leave Site.

Definition

Visual Basic .NET Public Function NearestPoint( _
ByVal pt As Point _
) As Single
C# public float NearestPoint(
Point pt
);
Managed C++ public: float* NearestPoint(
Point *pt
);

Parameters

pt System.Drawing.Point. The specified point, in ink space coordinates.

Return Value

System.Single. Returns the location on the Stroke object nearest to a specified Point Leave Site.

Examples

[C#]

This C# example returns the nearest location on the Stroke object, theStroke, to the Point Leave Site, theInkSpacePoint.

float theFIndex = theStroke.NearestPoint(theInkSpacePoint);
                

[VB.NET]

This Microsoft® Visual Basic® .NET example returns the nearest location on the Stroke object, theStroke, to the Point Leave Site, theInkSpacePoint.

Dim theFIndex As Single = theStroke.NearestPoint(theInkSpacePoint)
                

See Also