I want to create a batch file to first ping a share drive on start to see if it is ready to be mapped, then map when the ping is returned. As psuedo, something like this:
while true:
ping ipaddr -t
if (ping returned):
break
map drive
I believe the syntax would be something like:
:checkping
ping ipaddr -t
if ping:
goto mountZ
fi
goto checkping
:mountZ
net use Z:....
So how do I go about setting the ping in a usable variable to break the loop?