Click here to view all files
 
Adds a Point to the Polyline by copying the specified Point after any existing points in the specified path.

Namespace:  ESRI.ArcGISExplorer.Geometry
Assembly:  ESRI.ArcGISExplorer (in ESRI.ArcGISExplorer.dll) Version: 2.0.0.900 (2.0.0.900)

Syntax

C#
public void AddPoint(
	int pathIndex,
	Point pt
)
Visual Basic (Declaration)
Public Sub AddPoint ( _
	pathIndex As Integer, _
	pt As Point _
)

Parameters

pathIndex
Type: System..::.Int32
The index of the path to add a copy of pt to.
pt
Type: ESRI.ArcGISExplorer.Geometry..::.Point
A Point to copy in to the Polyline.

Remarks

This overload of the AddPoint method is often used as the simplest way to build up the vertices of a new multipart Polyline, by adding a single Point at a time to the specified path after any existing points in that path. The AddPoints()()() method may be a useful alternative if multiple points can be added at once. Alternatively if the vertices of a Polyline are known before the polylines object is instantiated, one or more points can be added in the overloaded Polyline constructors.

The specified pathIndex must already exist in the Polyline; use the AddPath()()() method to add a new path to the Polyline. If only working with single part polylines, an alternative is the AddPoint(Point) overload.

Note that the CoordinateSystem property of any new points added, inserted or set into existing an existing Polygon or Polyline will be discarded, and the coordinates (X and Y properties) of the point assumed to be in the same CoordinateSystem as the Polygon or Polyline to which they are added.

Exceptions

ExceptionCondition
System..::.ArgumentOutOfRangeExceptionThe specified pathIndex must already exist in the Polyline.

See Also

Relate Topics:
  AddPoint Method (Point)
Created by Atop CHM to web converter,© 2009 all right reserved.