Returns the existing entity corresponding to the Schema if it has been saved in the
Element, or an invalid entity otherwise.
Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 26.2.0.0 (26.2.0.0)
Syntax
C#
public Entity GetEntity( Schema schema )
Parameters
- schema Schema
- The Schema describing the Entity.
Return Value
EntityThe returned Entity.
Exceptions
Exception | Condition |
---|---|
ArgumentException | Reading of Entities of this Schema is not allowed to the current add-in. |
ArgumentNullException | A non-optional argument was null |