Skip to main content

Judgment-String

Command Description

Determine whether the string is all specified content (English letters, numbers, uppercase letters, and lowercase letters)

Command Prototype

bRet = IsSpecificStr(sText,sType)

Parameter Description

ParameterRequiredTypeDefaultDescription
sTextTruestring""The target string to be determined
sTypeTrueenum"letter"Determine the object's type: letters, numbers, uppercase letters, and lowercase letters

return

bRet,The variable used to save the output of the command.

Demo

TracePrint("----------------------judgment string---------------------- --") 
//-------------------------------------------------------------------------------
//[Remarks] Determine whether the string is all the specified content (select one of English letters, numbers, uppercase, and lowercase), if it is the specified content, return true, otherwise return false.
//Input parameter 1:
// sText--The target string to be judged.
//Input parameter 2:
// sType--judgment type, select one of English letters, numbers, uppercase, and lowercase.
//out parameters:
// bRet--The variable to which the output of the function call is saved.
//
//Command prototype: bRet=IsSpecificStr(sText,sType)
//-------------------------------------------------------------------------------
bRet=IsSpecificStr("UiBot","letter")
TracePrint(bRet)