- @echo off&setlocal enabledelayedexpansion
- set N=2
- set x=0
- set DstFolder=D:\abc
- for /d %%i in (*) do (
- pushd "%%i"
- for /f "delims=:" %%a in ('dir /b /a-d *.jpg') do (
- set /a x=x+1
- if !x! equ !N! (
- echo "%%a"
- copy "%%a" "%DstFolder%")
- popd
- ))
- pause
复制代码 回复 4# qixiaobin0715
上面是我的代码,我echo 没问题,
可是复制的时候说,
系统找不到指定文件,这是啥情况 |