Creates multiple split ProfileViews from an alignment with the specified ProfileViewStyle and ProfileViewBandSet.
Namespace: Autodesk.Civil.DatabaseServices
Assembly: AeccDbMgd (in AeccDbMgd.dll) Version: 13.8.0.280
Syntax
C#
public static ObjectIdCollection CreateMultiple( ObjectId alignmentId, Point3d insertPosition, string profileViewName, ObjectId profileViewBandSetId, ObjectId profileViewStyleId, MultipleProfileViewsCreationOptions multipleOptions, SplitProfileViewCreationOptions splitOptions, ProfileViewDatumType datumType )
VB
Public Shared Function CreateMultiple ( alignmentId As ObjectId, insertPosition As Point3d, profileViewName As String, profileViewBandSetId As ObjectId, profileViewStyleId As ObjectId, multipleOptions As MultipleProfileViewsCreationOptions, splitOptions As SplitProfileViewCreationOptions, datumType As ProfileViewDatumType ) As ObjectIdCollection
C++
public: static ObjectIdCollection^ CreateMultiple( ObjectId alignmentId, Point3d insertPosition, String^ profileViewName, ObjectId profileViewBandSetId, ObjectId profileViewStyleId, MultipleProfileViewsCreationOptions^ multipleOptions, SplitProfileViewCreationOptions^ splitOptions, ProfileViewDatumType datumType )
Parameters
- alignmentId ObjectId
- The ObjectId of the alignment.
- insertPosition Point3d
- The position at which the ProfileView is inserted.
- profileViewName String
- The name template of the ProfileViews.
- profileViewBandSetId ObjectId
- The ObjectId of the ProfileViewBandSet.
- profileViewStyleId ObjectId
- The ObjectId of the ProfileViewStyle.
- multipleOptions MultipleProfileViewsCreationOptions
- An object containing additional options for creating multiple ProfileViews.
- splitOptions SplitProfileViewCreationOptions
- An object containing additional options for creating split ProfileViews.
- datumType ProfileViewDatumType
- Specifies profile view datum (location of profile lines).
Return Value
ObjectIdCollectionExceptions
Exception | Condition |
---|---|
ArgumentException |
Thrown when:
|
Example
1ObjectId alignmentId = CivilApplication.ActiveDocument.GetSitelessAlignmentIds()[0]; 2Point3d insertPosition = new Point3d(0, 0, 0); 3string profileViewName = "Name of profile view"; 4ObjectId profileViewBandSetId = CivilApplication.ActiveDocument.Styles.ProfileViewBandSetStyles["Standard"]; 5ObjectId profileViewStyleId = CivilApplication.ActiveDocument.Styles.ProfileViewStyles["Standard"]; 6MultipleProfileViewsCreationOptions multipleOptions = new MultipleProfileViewsCreationOptions(); 7 8ObjectId firstSplitViewStyleId = CivilApplication.ActiveDocument.Styles.ProfileViewStyles["First View"]; 9ObjectId intermediateSplitVIewStyleId = CivilApplication.ActiveDocument.Styles.ProfileViewStyles["Intermediate View"]; 10ObjectId lastSplitViewStyleId = CivilApplication.ActiveDocument.Styles.ProfileViewStyles["Last View"]; 11double viewHeight = 100; 12SplitProfileViewCreationOptions splitOptions = new SplitProfileViewCreationOptions(viewHeight, firstSplitViewStyleId, intermediateSplitVIewStyleId, lastSplitViewStyleId); 13 14ProfileViewDatumType datumType = Autodesk.Civil.ProfileViewDatumType.MeanElevation; 15ObjectIdCollection profileViewIds = ProfileView.CreateMultiple(alignmentId, insertPosition, profileViewName, profileViewBandSetId, profileViewStyleId, multipleOptions, splitOptions, datumType);