正则表达式不能以0开头或输入0
只能输入有两位小数的正实数 ^+(.{2})?$能否进一步限定不能以0开头或是输入0及0.00[ 本帖最后由 silvay22 于 2009-1-17 20:59 编辑 ] dim $str,$s
$str="555.00"
$s=StringRegExp($str,"^[^0]++.{2}",0,1)
ConsoleWrite($s)
Returns 1 (matched) or 0 (no match)
[ 本帖最后由 class 于 2009-1-15 10:10 编辑 ] 不懂LZ的意思.... dim $str,$s
do
$str = InputBox("输入结果测试","请输入大于0的正实数",""," ","-1","-1","-1","-1")
Until StringRegExp($str,"^+\d*\.{0,1}\d{0,2}$",0)
MsgBox(0,'输入正确',$str) pcbar正解!高手就是高手!
页:
[1]