This document is archived and information here might be outdated.  Recommended version.


IPolycurve.SplitAtPoint Method (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Geometry > ESRI.ArcGIS.Geometry > Interfaces > IP > IPolycurve Interface > IPolycurve.SplitAtPoint Method
ArcGIS Developer Help

IPolycurve.SplitAtPoint Method

Introduces a new vertex into this polyline at the location on it closest to the input point.

[Visual Basic .NET]
Public Sub SplitAtPoint ( _
    ByVal splitPoint As IPoint, _
    ByVal projectOnto As Boolean, _
    ByVal createPart As Boolean, _
    ByRef SplitHappened As Boolean, _
    ByRef newPartIndex As Integer, _
    ByRef newSegmentIndex As Integer _
)
[C#]
public void SplitAtPoint (
    IPoint splitPoint,
    bool projectOnto,
    bool createPart,
    ref bool SplitHappened,
    ref int newPartIndex,
    ref int newSegmentIndex
);
[C++]
HRESULT SplitAtPoint(
  IPoint* splitPoint,
  VARIANT_BOOL projectOnto,
  VARIANT_BOOL createPart,
  Boolean* SplitHappened,
  System.Int32* newPartIndex,
  System.Int32* newSegmentIndex
);
[C++]
Parameters
splitPoint 

splitPoint is a parameter of type IPoint* projectOnto
projectOnto is a parameter of type bool createPart
createPart is a parameter of type bool SplitHappened [out]
SplitHappened is a parameter of type bool* newPartIndex [out]
newPartIndex is a parameter of type long* newSegmentIndex [out]
newSegmentIndex is a parameter of type long*

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Description

Adds a new vertex along the curve as the specified input point, or the projection onto the curve of the specified input point.

Remarks

projectOnto is an input parameter that determines if the output point will be located on the polycurve. If projectOnto is true and the input point is not already on the polycurve then the point is projected on the curve.

createPart is an input parameter that determines if parts (paths) have to be created. createPart must be FALSE for polygons.  For polylines, if createPart is TRUE, the part on which the new split point falls is split into two parts with the newly added vertex serving as the end of the first part and the beginning of the second.

SplitHappened is an output parameter that tells if the polycurve has been split or not.

newPartIndex is an output parameter that tells on which part (ring or path) the point has been introduced.

newSegmentIndex is an output parameter that tells what is the index of the new created segment. That index is zero based and part relative (start at 0 for each part).

 

SplitAtPoint Example

See Also

IPolycurve Interface