- @echo off&setlocal enabledelayedexpansion
- for /l %%x in (10001,1,11330) do (
- set y=%%x&set "flag="
- pushd "d:\分解\数据1\!y:~1!\lishi\"
- for /f "skip=1 delims=" %%i in ('dir /b /a-d /o-n *.txt') do (
- if not defined flag (
- copy "%%i" "d:\分解\数据2\!y:~1!.txt"
- set flag=1
- )
- )
- popd
- )
复制代码
|