Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Batch file pauses unexpectedly

Status
Not open for further replies.

jonnysnow

Programmer
Apr 10, 2003
36
US
I wrote a batch file that does a whole slew of things-- builds environment variables, copies files, does text substitution, runs DBMS/Copy in batch mode, runs SAS in batch mode, etc.

This was working smoothly, but recently, it's been stopping at the end of some of the steps (like DBMS/Copy) and just waiting. When I click in the MS-DOS window and re-establish focus, the batch file starts right up again.

Why is this stopping, and how do I keep the focus in the MS-DOS window to let the batch file complete??


The way I've been running this is by opening an MS-DOS prompt window (on Windows 98) Start --> Programs --> MS-DOS prompt.

Then I navigate to the correct directory, and I type the batch file name at the prompt.

One other thing: I sometimes use the START /WAIT command to try to keep things properly synchronized. But this worked OK before.
 
You could try this: create a shortcut to the batch file on the desktop, then right click on it and select properties. Then click on the "misc" tab and set the idle sesitivity to low. make sure that the "always suspend" box is unchecked.Then click "apply" This process creates a .pif file for the app(program information file). Setting the sensitivity to low is supposed to give the dos app more priority.

If you're going through Hell...keep going... (Winston Churchill)
RocKeRFelLerZ
 
I checked the "Properties" on my MS-DOS prompt (which is a shortcut to C:\WINDOWS\COMMAND.COM).

Sure enough, the "Always suspend" box was checked-- this must be what changed somewhere along the line. I unchecked this box and reran it, and it seems fine.

Thanks!
 
I am not sure you want to change that shortcut. That is the global MS-DOS prompt setting. I would do like the previous suggestion and just change that shortcuts properties.

Jon

There is much pleasure to be gained from useless knowledge. (Bertrand Russell)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top