public CivilObject SetStyle(CivilStyle civilStyle) { Autodesk.AutoCAD.ApplicationServices.Document doc = Autodesk.AutoCAD.ApplicationServices.Application.DocumentManager.MdiActiveDocument; Autodesk.AutoCAD.DatabaseServices.Database db = doc.Database; using (Autodesk.AutoCAD.DatabaseServices.Transaction trans = db.TransactionManager.StartTransaction()) { Autodesk.Civil.DatabaseServices.Entity entity = (Autodesk.Civil.DatabaseServices.Entity)trans.GetObject(_curCivilObject.ObjectId, OpenMode.ForWrite); entity.StyleId = civilStyle.InternalObjectId; trans.Commit(); } return(this); }
public static SectionViewTotalVolumeTable ByName(Autodesk.AutoCAD.DynamoNodes.Document document, string styleName) { SectionViewTotalVolumeTable retStyle = new SectionViewTotalVolumeTable(CivilStyle.DBObjectByName(document, CivilDocument.GetCivilDocument(document.AcDocument.Database).Styles.TableStyles.SectionViewTotalVolumeTableStyles, styleName), false); return(retStyle); }
public static ParcelAreaTable ByName(Autodesk.AutoCAD.DynamoNodes.Document document, string styleName) { ParcelAreaTable retStyle = new ParcelAreaTable(CivilStyle.DBObjectByName(document, CivilDocument.GetCivilDocument(document.AcDocument.Database).Styles.TableStyles.ParcelAreaTableStyles, styleName), false); return(retStyle); }
public static ParcelAreaTable ByIndex(Autodesk.AutoCAD.DynamoNodes.Document document, int index) { ParcelAreaTable retStyle = new ParcelAreaTable(CivilStyle.DBObjectByIndex(document, CivilDocument.GetCivilDocument(document.AcDocument.Database).Styles.TableStyles.ParcelAreaTableStyles, index), false); return(retStyle); }
public static QTOMaterialTable ByName(Autodesk.AutoCAD.DynamoNodes.Document document, string styleName) { QTOMaterialTable retStyle = new QTOMaterialTable(CivilStyle.DBObjectByName(document, CivilDocument.GetCivilDocument(document.AcDocument.Database).Styles.TableStyles.QuantityTakeoffMaterialTableStyles, styleName), false); return(retStyle); }
public static SurfaceUserDefinedContourTable ByName(Autodesk.AutoCAD.DynamoNodes.Document document, string styleName) { SurfaceUserDefinedContourTable retStyle = new SurfaceUserDefinedContourTable(CivilStyle.DBObjectByName(document, CivilDocument.GetCivilDocument(document.AcDocument.Database).Styles.TableStyles.SurfaceUserDefinedContourTableStyles, styleName), false); return(retStyle); }
public static QTOTotalVolumeTable ByIndex(Autodesk.AutoCAD.DynamoNodes.Document document, int index) { QTOTotalVolumeTable retStyle = new QTOTotalVolumeTable(CivilStyle.DBObjectByIndex(document, CivilDocument.GetCivilDocument(document.AcDocument.Database).Styles.TableStyles.QuantityTakeoffTotalVolumeTableStyles, index), false); return(retStyle); }
public static AlignmentSegmentTable ByIndex(Autodesk.AutoCAD.DynamoNodes.Document document, int index) { AlignmentSegmentTable retStyle = new AlignmentSegmentTable(CivilStyle.DBObjectByIndex(document, CivilDocument.GetCivilDocument(document.AcDocument.Database).Styles.TableStyles.AlignmentSegmentTableStyles, index), false); return(retStyle); }
public static SurfaceElevationTable ByIndex(Autodesk.AutoCAD.DynamoNodes.Document document, int index) { SurfaceElevationTable retStyle = new SurfaceElevationTable(CivilStyle.DBObjectByIndex(document, CivilDocument.GetCivilDocument(document.AcDocument.Database).Styles.TableStyles.SurfaceElevationTableStyles, index), false); return(retStyle); }
public static AlignmentSpiralTable ByName(Autodesk.AutoCAD.DynamoNodes.Document document, string styleName) { AlignmentSpiralTable retStyle = new AlignmentSpiralTable(CivilStyle.DBObjectByName(document, CivilDocument.GetCivilDocument(document.AcDocument.Database).Styles.TableStyles.AlignmentSpiralTableStyles, styleName), false); return(retStyle); }