ArcGIS Pro 2.6 API Reference Guide
CreatePolyline(Segment,SpatialReference) Method
Example 

ArcGIS.Core.Geometry Namespace > PolylineBuilder Class > CreatePolyline Method : CreatePolyline(Segment,SpatialReference) Method
Segment to create the polyline.
(Optional) The SpatialReference. The default value is null. If spatialReference is null, then the spatial reference will be inherited from segment.
Convenience method to create a new instance of the Polyline class.
Syntax
public static Polyline CreatePolyline( 
   Segment segment,
   SpatialReference spatialReference
)
Public Overloads Shared Function CreatePolyline( _
   ByVal segment As Segment, _
   Optional ByVal spatialReference As SpatialReference _
) As Polyline

Parameters

segment
Segment to create the polyline.
spatialReference
(Optional) The SpatialReference. The default value is null. If spatialReference is null, then the spatial reference will be inherited from segment.

Return Value

Exceptions
ExceptionDescription
segment is null.
Example
// create the circular arc
MapPoint fromPt = MapPointBuilder.CreateMapPoint(2, 1);
MapPoint toPt = MapPointBuilder.CreateMapPoint(1, 2);
Coordinate2D interiorPt = new Coordinate2D(1 + Math.Sqrt(2) / 2, 1 + Math.Sqrt(2) / 2);

EllipticArcSegment circularArc = EllipticArcBuilder.CreateEllipticArcSegment(fromPt, toPt, interiorPt);

// buffer the arc
Polyline polyline = PolylineBuilder.CreatePolyline(circularArc);
Geometry lineBuffer = GeometryEngine.Instance.Buffer(polyline, 10);
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 7

See Also

Reference

PolylineBuilder Class
PolylineBuilder Members
Overload List