|
代码一
- @echo off
- Setlocal Enabledelayedexpansion
- for /f "delims=" %%i in ('wmic datafile where "filename='ospp' and Extension='vbs'" get name') do (set /a n+=1 & if !n! equ 2 set "V=%%i")
- echo %V%
- pause
复制代码
代码二
- @echo off
- Setlocal Enabledelayedexpansion
- for /f "skip=1 delims=" %%i in ('wmic datafile where "filename='ospp' and Extension='vbs'" get name') do (set /a n+=1 & if !n! equ 1 set "V=%%i")
- echo %V%
- pause
复制代码
|
|