Creates an Alignment from the specified Polyline, Polyline2d or Polyline3d.
public static ObjectId Create( CivilDocument document, PolylineOptions plineOptions, string alignmentName, string siteName, string layerName, string styleName, string labelSetName )
Public Shared Function Create ( document As CivilDocument, plineOptions As PolylineOptions, alignmentName As String, siteName As String, layerName As String, styleName As String, labelSetName As String ) As ObjectId
public: static ObjectId Create( CivilDocument^ document, PolylineOptions plineOptions, String^ alignmentName, String^ siteName, String^ layerName, String^ styleName, String^ labelSetName )
| Exception | Condition |
|---|---|
| ArgumentException |
Thrown when:
|
1// create some polyline options for creating the new alignment 2PolylineOptions plops = new PolylineOptions(); 3plops.AddCurvesBetweenTangents = true; 4plops.EraseExistingEntities = true; 5plops.PlineId = res.ObjectId; 6 7// uses an existing Alignment Style and Label Set Style named "Standard" (for example, from 8// the Civil 3D (Imperial) NCS.dwt template. This call will fail if the named styles 9// don't exist. 10ObjectId testAlignmentID = Alignment.Create(doc, plops, "New Alignment", null, "0", "Standard", "Standard");