validation - How to check if a string is alphanumeric in VBScript? -
is there function isnumeric() in vbscript check if string contains alphanumeric (a-za-z0-9) characters? or can determined regular expressions?
use ^ feature (not in class) of regexps search characters not in (a-za-z0-9):
>> set r = new regexp >> r.pattern = "[^a-za-z0-9]" >> each t in array("aa0", "a.0") >> wscript.echo t, cstr(r.test(t)) >> next >> aa0 false a.0 true
Comments
Post a Comment