Utilities.IsValidIdent Method

Applies to TestComplete 15.63, last modified on April 10, 2024
This method is obsolete. See the Remarks section below.

Description

Use the Utilities.IsValidIdent method to determine whether the string specified by the Ident parameter is a valid JScript, C++Script, C#Script or DelphiScript identifier. A valid identifier may include only alphanumeric characters ('A'..'Z', 'a'..'z' and '0'..'9') and underscores ('_') and cannot start with a digit.

You can use this function, for example, to see if the names of properties and methods you create via the ODT project item are valid.

Declaration

Utilities.IsValidIdent(Ident)

Ident [in]    Required    String    
Result Boolean

Applies To

The method is applied to the following object:

Parameters

The method has the following parameter:

Ident

Specifies the string that TestComplete will check to determine whether it is a valid JScript, C++Script, C#Script or DelphiScript identifier.

Result Value

The method returns True if the string specified by the Ident parameter is a valid JScript, C++Script, C#Script or DelphiScript identifier. Otherwise, the method returns False.

Remarks

The Utilities.IsValidIdent method is obsolete and supported for backward compatibility only. To test for valid JScript, C++Script, C#Script or DelphiScript identifiers, use the aqUtils.IsValidIdent method.

You can also use this function to validate VBScript identifiers. These identifiers must match all the rules applied to the JScript, C++Script, C#Script and DelphiScript identifiers with the only exception: a VBScript identifier cannot start with an underscore (_).

See Also

Object-Driven Testing
IsValidIdent Method

Highlight search results