SetValueAsColor Method


Sets the value property as a color.

Namespace: Autodesk.Revit.DB.Visual
Assembly: RevitAPI (in RevitAPI.dll) Version: 22.0.0.0 (22.1.0.0)
Since: 2018.1

Syntax

C#
public void SetValueAsColor(
	Color color
)
Visual Basic
Public Sub SetValueAsColor ( _
	color As Color _
)
Visual C++
public:
void SetValueAsColor(
	Color^ color
)

Parameters

color
Type: Autodesk.Revit.DB Color
The new color.

Exceptions

Exception Condition
Autodesk.Revit.Exceptions ArgumentException The input value is invalid for this AssetPropertyDoubleArray4d property.
Autodesk.Revit.Exceptions ArgumentNullException A non-optional argument was null
Autodesk.Revit.Exceptions InvalidOperationException The asset property is not editable.

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 →