NamingUtilsIsValidName Method |
Identifies if the input string is valid for use as an object name in Revit.
Namespace: Autodesk.Revit.DBAssembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)
Syntaxpublic static bool IsValidName(
string string
)
Public Shared Function IsValidName (
string As String
) As Boolean
public:
static bool IsValidName(
String^ string
)
static member IsValidName :
string : string -> bool
Parameters
- string String
-
The name to validate.
Return Value
Boolean
True if the name is valid for use as a name in Revit, false if it contains prohibited characters and is invalid.
Exceptions
Remarks
This routine checks only for prohibited characters in the string.
When setting the name for an object there are other specific considerations which are checked
(for example, the same name cannot be used twice for different elements of the same type).
This routine does not check those conditions.
See Also