level 2
TMAC123happy
楼主
@echo off
set "task=postgres.exe" echo 开始查询进程是否存在
tasklist|find /i "%task%">nul
for /f %%i in ('wmic process where "name='%task%'" get executablepath') do (
echo %%i
)
pause>nul
2018年02月08日 01点02分
1
set "task=postgres.exe" echo 开始查询进程是否存在
tasklist|find /i "%task%">nul
for /f %%i in ('wmic process where "name='%task%'" get executablepath') do (
echo %%i
)
pause>nul
