Revit 2025 API
Direct |
Add a definition to be reused by instances. Adding a definition type will change how the instances are created.
When asked to create a definition, the library object will look for a corresponding type object.
If one is found, it will create an instance of geometry stored in the type object. If it is not found,
the library will look for a list of geometry objects stored as definition, and will copy and transform these
to create an instance.
Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)
Syntax
public void AddDefinitionType( string id, ElementId typeId )
Public Sub AddDefinitionType ( id As String, typeId As ElementId )
public: void AddDefinitionType( String^ id, ElementId^ typeId )
member AddDefinitionType : id : string * typeId : ElementId -> unit
Parameters

Exception | Condition |
---|---|
ArgumentNullException | A non-optional argument was null |
See Also