@echo off
:yy
setlocal
set /p LotID=请输入Lot ID(小写):
if not "%lotid:~0,2%"=="1a" set "gs=t"
if "%gs%"=="t" echo Lot ID输入错误!&endlocal&goto yy
echo %lotid:~6,4%|findstr "^[0-9]*$" >nul|| (
echo\&echo Lot ID输入错误!
endlocal&goto yy
)
set "str=%lotid%"
set "str=%str:"= %"
:next
if not "%str%"=="" (
set /a num+=1
set "str=%str:~1%"
goto next
)
if not "%num%"=="10" set "chd=aa"
if "%chd%"=="aa" echo Lot ID输入错误!&endlocal&goto yy
set "a=%LotID:~0,6%"
set "b=%LotID:~6,2%"
set "c=%LotID:~8,2%"
:zz
setlocal
set /p piat=请输入Code:
set "lu=%piat%"
set "m=%lu%"
md %lotid%-%m%
(echo open 10.20.1.1
echo admin
echo admin
echo bin
echo lcd %dektop%
echo lcd %lotid%-%m%
echo cd %lu%/%a%/%b%/%c%/img
echo bin
echo prompt off
echo mget *.jpg
echo pause
)>%tmp%\temp.htp
ftp -s:%tmp%\temp.htp
@ del /q /s %tmp%\temp.htp
start explorer %lotid%-%m%
echo pause作者: haichuan5121 时间: 2015-2-22 13:22