To Pause or not to pause……

As usual my friend Ewoudt is always presenting me with fun little things to think about.Here we go.

Scenario:Pausing  execution in a windows batch file

And what followed:

Well for one i need to explain the scenario a bit better. During the execution of windows batch file the processing needs to stop for a while

while something else occurs. In this case while a service stopped. Once it had stopped, the processing needs to continue.

Now i am aware that windows posses a pause command , but the stops execution and waits for the user to press a key to continue which is not what we need in this

case.

The Clever little hack :

Well this one really caught me off guard , the execution only needed to stop for a few seconds before continuing

so all that he did was a simple ping 127.0.0.1 and boom few seconds till the service stopped.

Granted there may be other cleaner ways of doing this ,this was to cool to pass over in the end.

No Comments Yet

No comments yet.

Comments RSS TrackBack Identifier URI

Leave a comment