Level CreateLevel(Autodesk.Revit.DB.Document document) { // The elevation to apply to the new level double elevation = 20.0; // Begin to create a level Level level = Level.Create(document, elevation); if (null == level) { throw new Exception("Create a new level failed."); } // Change the level name level.Name = "New level"; return level; }
ref: http://help.autodesk.com/view/RVT/2017/ENU/?guid=GUID-AA1B1CD4-3988-4F90-9C19-CE0DC1EC2039
반응형
'cs' 카테고리의 다른 글
Tutorials: My First Revit Plug-in (0) | 2021.10.05 |
---|---|
reading a csv file - code evolved (0) | 2018.04.01 |
Revit API Developers Guide (0) | 2018.03.28 |
Youtube: Revit API C# Getting Started (0) | 2018.03.22 |
Creating a grid with a line or an arc (0) | 2018.03.21 |