ArcGIS Pro 3.8 API Reference Guide
ArcGIS.Core.Geometry Namespace / PolylineBuilderEx Class / CreatePolyline Method / CreatePolyline(Envelope,SpatialReference) Method
The envelope to create the polyline. Note that if the envelope has Z-values, they will be interpolated for the upper right and lower left vertices.
(Optional) The SpatialReference. The default value is null. If spatialReference is null, then the spatial reference will be inherited from envelope.
Example

In This Topic
    CreatePolyline(Envelope,SpatialReference) Method
    In This Topic
    Convenience method to create a new instance of the Polyline class.
    Syntax
    public static Polyline CreatePolyline( 
       Envelope envelope,
       SpatialReference spatialReference
    )
    Public Overloads Shared Function CreatePolyline( _
       ByVal envelope As Envelope, _
       Optional ByVal spatialReference As SpatialReference _
    ) As Polyline

    Parameters

    envelope
    The envelope to create the polyline. Note that if the envelope has Z-values, they will be interpolated for the upper right and lower left vertices.
    spatialReference
    (Optional) The SpatialReference. The default value is null. If spatialReference is null, then the spatial reference will be inherited from envelope.

    Return Value

    Exceptions
    ExceptionDescription
    envelope is null.
    Remarks
    HasZ, HasM and HasID attributes are inherited from the input envelope.
    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