@echo off

pushd %~dp0

for /f "tokens=1*" %%b in (counter.txt) do set value=%%b
if %value% geq 2 goto :2
   ) else (
goto :1

:1
echo.2 >counter.txt
wmic Path win32_process Where "Caption Like 'DesktopInfo64.exe'" Call Terminate >nul 2>nul
start DesktopInfo1.exe
exit

:2
echo.1 >counter.txt
wmic Path win32_process Where "Caption Like 'DesktopInfo64.exe'" Call Terminate >nul 2>nul
start DesktopInfo2.exe
exit




