-------zzz.bat------
sleep 2
ping 192.168.3.52
ping 192.168.3.48
arp -a>arpt.txt
arp -d
START CMD /C CALL "arpt.bat" [args [...]]
exit
--------arpt.bat---------
set path=C:\Java\bin
javac apples.java
java apples
cls
START CMD /C CALL "zzz.bat" [args [...]]
exit
------test.bat------
:startloop
ping 192.168.3.52
ping 192.168.3.48
sleep 2
goto startloop
'zzz.bat' works fine first time but when 'arpt.bat' calls 'zzz.bat' again error comes as 'ping' is not recognized as internal or external command..........whereas 'test.bat' works perfectly....any solutions???
cannot ping same address second time in a loop
Moderator: DosItHelp
Re: cannot ping same address second time in a loop
If you overwrite the PATH environment variable then you have to call the commands by their full name. Eg.:
Regards
aGerman
Code: Select all
%systemroot%\system32\ping.exe 192.168.3.52
Regards
aGerman
Re: cannot ping same address second time in a loop
set path=%path%;C:\Java\bin