RVTDocs.com
Namespace: Autodesk.Revit.DB Class: Parameter

Parameter.AsValueString

Method
Description:
Get the parameter value as a string with units.
Syntax
Examples
String ShowValueParameterInformation(Parameter attribute)
{
    string paramValue = null;
    switch (attribute.StorageType)
    {
        case StorageType.Integer:
            if (SpecTypeId.Boolean.YesNo
                                == attribute.Definition.GetDataType())
            {
                paramValue = null;
            }
            else
            {
                paramValue = attribute.AsValueString();
            }
            break;
        case StorageType.Double:
            paramValue = attribute.AsValueString();
            break;
        default:
            paramValue = null;
            break;
    }

    return paramValue;
}