Ping the Ip address with the delay of 1 sec

September 16, 2010 at 22:56:59
Specs: Windows XP
I want to write a program to ping the network with the delay of 1 second and beside it, timestamp should appear. Hence, I should get to know the time of each ping.
Also, I want to store the output in notepad.

The output should be like this

Reply from 10.145.61.172: bytes=32 time<1ms TTL=128 10:53:26
Reply from 10.145.61.172: bytes=32 time<1ms TTL=128 10:53:27
Reply from 10.145.61.172: bytes=32 time<1ms TTL=128 10:53:28


I have written a program. Can anyone please modify it?

:START
echo %time >>C:\ john.txt
time/t && Ping 10.142.22.221 >>C:\ john.txt
goto START


See More: Ping the Ip address with the delay of 1 sec

Report •


#1
September 18, 2010 at 08:41:27
You just need one line (see ping -? and it will explain how it works):

ping -t -w 1000 10.145.61.172 >> C:\john.txt


Report •
Related Solutions


Ask Question