Set Method (FamilyParameter, ElementId)


Set the ElementId value of a family parameter of the current family type.

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 24.0.0.0 (24.0.0.0)

Syntax

C#
public void Set(
	FamilyParameter familyParameter,
	ElementId value
)
Visual Basic
Public Sub Set ( _
	familyParameter As FamilyParameter, _
	value As ElementId _
)
Visual C++
public:
void Set(
	FamilyParameter^ familyParameter, 
	ElementId^ value
)

Parameters

familyParameter
Type: Autodesk.Revit.DBFamilyParameter
A family parameter of the current type.
value
Type: Autodesk.Revit.DBElementId
The new value for family parameter.

Exceptions

ExceptionCondition
Autodesk.Revit.ExceptionsArgumentException Thrown when the storage type of family parameter is not ElementId --or-- The input ElementId does not represent either a valid element in the document or InvalidElementId.
Autodesk.Revit.ExceptionsArgumentOutOfRangeException Thrown when the input ElementId is not valid as a value for this FamilyParameter.
Autodesk.Revit.ExceptionsInvalidOperationException Thrown when the family parameter is determined by formula, or the current family type is invalid.

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 →