test1.bat
@echo off
set /p input=请输入:
echo %input% | findstr "\<一\> \<二\> \<三\> \<四\> \<五\> \<六\> \<七\> \<八\> \<九\> \<十\>" >nul || echo 必须输入大写数字!
瞎试验出来的!
但是,还不知道为什么???
是不是CMD把"一 二 三 四 五 六 七 八 九 十"当成"特殊字符"???
请DX指教!!!
test2.bat
@echo off
set /p input=请输入:
echo %input% | findstr "" || echo 必须输入小写数字!
F:\>test2.bat
请输入:12 34
12 34
F:\>test2.bat
请输入:一
必须输入小写数字!
Last edited by xycoordinate on 2007-3-17 at 05:28 PM ]