| ElementGetGeometryObjectFromReference Method | 
   Retrieve one geometric primitive contained in the element given a reference.
Namespace: Autodesk.Revit.DBAssembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)
 Syntax
Syntaxpublic GeometryObject GetGeometryObjectFromReference(
	Reference reference
)
Public Function GetGeometryObjectFromReference ( 
	reference As Reference
) As GeometryObject
public:
GeometryObject^ GetGeometryObjectFromReference(
	Reference^ reference
)
member GetGeometryObjectFromReference : 
        reference : Reference -> GeometryObject Parameters
- reference  Reference
- 
   The geometric object referenced by this instance will be retrieved from the model.
Return Value
GeometryObject
   The geometric object referenced by the input reference.
 Exceptions
Exceptions| Exception | Condition | 
|---|
| ArgumentException | The id of this element is not same as that referenced by reference | 
| ArgumentNullException | A non-optional argument was null | 
| InvalidOperationException | The element id held by the input reference is not same as the id of this element.
   The geometric information could not be taken for this element. | 
 Remarks
Remarks
   It will return the last geometric object in the path.
    will be returned if related geometric object could not be found in the model.
 See Also
See Also