Parameter Property (BuiltInParameter)


Retrieves a parameter from the element given a parameter id.

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

Syntax

C#
public Parameter this[
	BuiltInParameter parameterId
] { get; }
Visual Basic
Public ReadOnly Property Parameter ( _
	parameterId As BuiltInParameter _
) As Parameter
	Get
Visual C++
public:
property Parameter^ Parameter[BuiltInParameter parameterId] {
	Parameter^ get (BuiltInParameter parameterId);
}

Parameters

parameterId
Type: Autodesk.Revit.DB BuiltInParameter
The built in parameter id of the parameter to be retrieved.

Remarks

Parameters are a generic form of data storage within elements. The parameters are visible through the Autodesk Revit user interface in the Element Properties dialog. This method uses a built in parameter id to access the parameter. Autodesk Revit has a large number of built in parameters that are available via an enumerated type.

Examples

Copy C#
public Parameter FindWithBuiltinParameterID(Wall wall)
{
    //Use the WALL_BASE_OFFSET paramametId
    // to get the base offset parameter of the wall.
    BuiltInParameter paraIndex = BuiltInParameter.WALL_BASE_OFFSET;
    Parameter parameter = wall.get_Parameter(paraIndex);

    return parameter;
}
Copy VB.NET
Public Function FindWithBuiltinParameterID(wall As Wall) As Parameter
    'Use the WALL_BASE_OFFSET paramametId
    ' to get the base offset parameter of the wall.
    Dim paraIndex As BuiltInParameter = BuiltInParameter.WALL_BASE_OFFSET
    Dim parameter As Parameter = wall.Parameter(paraIndex)

    Return parameter
End Function

See Also