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


IConstructMultipoint.ConstructDivideLength Method (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Geometry > ESRI.ArcGIS.Geometry > Interfaces > IC > IConstructMultipoint Interface > IConstructMultipoint.ConstructDivideLength Method
ArcGIS Developer Help

IConstructMultipoint.ConstructDivideLength Method

Places points along the input curve each seperate by the specified distance.

[Visual Basic .NET]
Public Sub ConstructDivideLength ( _
    ByVal inCurve As ICurve, _
    ByVal separationDistance As Double _
)
[C#]
public void ConstructDivideLength (
    ICurve inCurve,
    double separationDistance
);
[C++]
HRESULT ConstructDivideLength(
  ICurve* inCurve,
  double separationDistance
);
[C++]
Parameters
inCurve 

inCurve is a parameter of type ICurve* separationDistance
separationDistance is a parameter of type double

Product Availability

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

Description

Constructs a Multipoint consisting of the endpoints of the Curve and the points along the length of the curve spaced a given distance apart from each other starting at the curve's From point and ending at the To point.

Remarks

If the final inner point is too close to the To point, that inner point is not included in the constructed multipoint. 

 

Multipoint Construct Divide Length

[C#]

//This example demonstrates how to use ConstructDivideLentgth
private void ConstructDivideLength()
{
    IPoint centerPoint = new PointClass();
    centerPoint.PutCoords(10, 0);
    IPoint fromPoint = new PointClass();
    fromPoint.PutCoords(0, 0);
    IPoint toPoint = new PointClass();
    toPoint.PutCoords(0, 20);
    ICircularArc circularArcConstruction = new CircularArcClass();
    circularArcConstruction.PutCoords(centerPoint, fromPoint, toPoint, esriArcOrientation.esriArcClockwise);
    IConstructMultipoint constructMultipoint = new MultipointClass();
    constructMultipoint.ConstructDivideLength(circularArcConstruction as ICurve, 10);
    IPointCollection pointCollection = constructMultipoint as IPointCollection;
    System.Windows.Forms.MessageBox.Show("Number of points is: " + pointCollection.PointCount);
}

[Visual Basic .NET]

    Sub ConstructDivideEqual_ConstructDivideLength_Example()
        Dim pCArc As ICircularArc, pConstructMultipoint As IConstructMultipoint
        Dim pCenter As IPoint, pFrom As IPoint, pTo As IPoint
        Dim ptc As IPointCollection
        pCArc = New CircularArc
        pCenter = New Point
        pCenter.PutCoords(10, 0)
        pFrom = New Point
        pFrom.PutCoords(0, 0)
        pTo = New Point
        pTo.PutCoords(0, 20)
        pCArc.PutCoords(pCenter, pFrom, pTo, esriArcOrientation.esriArcClockwise)
        pConstructMultipoint = New Multipoint
        pConstructMultipoint.ConstructDivideLength(pCArc, pCArc.Length / 11)
        ptc = pConstructMultipoint
        Debug.Print("Number of points is: " & ptc.PointCount)
    End Sub

See Also

IConstructMultipoint Interface