Creates a DirectShapeType element.
Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 17.0.0.0 (17.0.1090.0)
Since: 2015
Syntax
C# |
---|
|
Visual Basic |
---|
|
Visual C++ |
---|
|
Parameters
- document
- Type: Autodesk.Revit.DB Document
The document that will contain the new element.
- name
- Type: System String
Name of the DirectShapeType.
- categoryId
- Type: Autodesk.Revit.DB ElementId
Id of the category assigned to this DirectShapeType. Must be a valid category id.
Return Value
The new DirectShapeType.Exceptions
Exception | Condition |
---|---|
Autodesk.Revit.Exceptions ArgumentException | Document document may not contain DirectShape or DirectShapeType objects. -or- Element id categoryId may not be used as a DirectShape category. |
Autodesk.Revit.Exceptions ArgumentNullException | A non-optional argument was NULL |