回复 4# xfgc
- @echo off
- cd /d "%~dp0"
- :loop
- for /f %%a in ('tasklist ^|find /i /c "fds.exe"') do (
- if %%a lss 40 (
- call :1
- ) else (
- timeout 5 >nul
- goto :loop
- )
- )
- if not defined m (
- echo All simulations completed.
- pause
- exit
- ) else (
- timeout 1 >nul
- goto :loop
- )
-
- :1
- set m=
- for /r %%i in (*.fds) do (
- if not defined _"%%i" (
- set _"%%i"=1
- set m=1
- start cmd /k call fds_local -p 4 "%%i"
- exit /b
- )
- )
- exit /b
复制代码
|