FindByName Method


Global Parameters Manager Find By Name Method

Finds whether a global parameter with the given name exists in the input document.

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 25.3.0.0 (25.3.0.0)
Syntax
public static ElementId FindByName(
	Document document,
	string name
)

Parameters

document Document
The document expected to contain the global parameter.
name String
Name of the global parameter

Return Value

ElementId
ElementId of the parameter element, or InvalidElementId if it was not found.
Exceptions
Exception Condition
ArgumentNullException A non-optional argument was null
Remarks
No exception is thrown when no parameter with such a name exists in the document; instead, the method returns an ElementId.InvalidElementId.
See Also
ArchiLabs Desktop

Put AI to work inside Revit.

Give Desktop your instructions and project files to build Revit families, update model elements, and create views and schedules. Works directly in Revit and AutoCAD.

Explore Desktop →