|Thank you very much jowah, I think I understand, you mean if launching through CMD you would type ping.bat hostname and the hostname would pass to the %1 variable?|
I have tried this, i.e. in CMD
However I still get the error:
"The process cannot access the file because it is being used by another process."
I need to time this to run every 30 mins or so, so the way I was planning to accomplish this was using scheduled tasks to run the ping.bat file every 30 mins.
Do you know if it is possible to still pass the hostname to %1 with scheduled tasks?
Sorry about this, I haven't used CMD in a long time and when I did, I was never great at it.