RVTDocs.com

IsValidDataType

Method
Description:
Tests whether the input Data Type is valid as a type of a global parameter.
Remarks:
Since most data types but not all are supported by global parameters, it is reasonable to test a ParameterType before attempting to create a global parameter of it.
Syntax
public static bool IsValidDataType(
	ParameterType datatype
)
Parameters
Parameter Type Description
datatype Autodesk.Revit.DB.ParameterType Type of the data the parameter is to store.
Return Value
Type Description
Autodesk.Revit.Exceptions.ArgumentOutOfRangeException True if the data type is suitable for a global parameter; False otherwise.
Exceptions
Exception Condition
Autodesk.Revit.Exceptions.ArgumentOutOfRangeException A value passed for an enumeration argument is not a member of that enumeration