SetReferences Method


Selection Set References Method

Selects the references. The references can be an element or a subelement in the host or a linked document.

Namespace: Autodesk.Revit.UI.Selection
Assembly: RevitAPIUI (in RevitAPIUI.dll) Version: 27.0.4.0 (27.0.4.0)
Syntax
public void SetReferences(
	IList<Reference> references
)

Parameters

references IList Reference
The references to be selected.
Exceptions
Exception Condition
ArgumentNullException A non-optional argument was null
InvalidOperationException Changing the selection is not permitted while handling SelectionChanged Event.
Remarks
This function will select the specified references and update the UI.
See Also
ArchiLabs

Stop fighting Revit automation.

Build repeatable BIM design and documentation workflows with scripts, data, and AI in one place, without wrestling brittle one-off automations.

Try ArchiLabs →