ArcGIS Pro 3.8 API Reference Guide
ArcGIS.Core.Geometry Namespace / PolylineBuilderEx Class / CreatePolyline Method / CreatePolyline(IEnumerable<Polyline>,SpatialReference) Method
Parts to create the polyline. The spatial references of the polylines are checked for compatibility.
(Optional) The SpatialReference. The default value is null. If spatialReference is null, then the spatial reference will be inherited from polylines. which requires traversing through the enumeration of polylines. For improved performance, use CreatePolyline(IEnumerable<Polyline>,AttributeFlags,SpatialReference).
Example

In This Topic
    CreatePolyline(IEnumerable<Polyline>,SpatialReference) Method
    In This Topic
    Convenience method to create a new instance of the Polyline class.
    Syntax
    Public Overloads Shared Function CreatePolyline( _
       ByVal polylines As IEnumerable(Of Polyline), _
       Optional ByVal spatialReference As SpatialReference _
    ) As Polyline

    Parameters

    polylines
    Parts to create the polyline. The spatial references of the polylines are checked for compatibility.
    spatialReference
    (Optional) The SpatialReference. The default value is null. If spatialReference is null, then the spatial reference will be inherited from polylines. which requires traversing through the enumeration of polylines. For improved performance, use CreatePolyline(IEnumerable<Polyline>,AttributeFlags,SpatialReference).

    Return Value

    Exceptions
    ExceptionDescription
    Incompatible spatial references.
    polylines is null.
    Remarks
    The HasZ, HasM and HasID properties are inherited from polylines. If you don't want these properties to be inherited, set them yourself by using CreatePolyline(IEnumerable<Polyline>,AttributeFlags,SpatialReference).
    Example
    Construct a Polyline - from a Cubic Bezier
    {
      polyline = PolylineBuilderEx.CreatePolyline(bezierSegment);
    }
    Requirements

    Target Platforms: Windows 11 Home, Pro, Enterprise (64 bit)

    ArcGIS Pro version: 3.0 or higher.
    See Also