Peculiar batch file behavior

  • Thread starter Thread starter Knack
  • Start date Start date
K

Knack

I want to test my batch file, but it won't run if I double-click on its file
icon (.bak), nor if I type its path into the Start > Run field, and click
OK. A blank <cmd.exe> window appears. However, if I copy the contents of
that file and paste it into a command prompt window, then it runs. Why?
Does <cmd.exe> require some sort of initial setup configuration before it
can run batch files?
 
Knack said:
I want to test my batch file, but it won't run if I double-click on its file
icon (.bak), nor if I type its path into the Start > Run field, and click
OK. A blank <cmd.exe> window appears. However, if I copy the contents of
that file and paste it into a command prompt window, then it runs. Why?
Does <cmd.exe> require some sort of initial setup configuration before it
can run batch files?

Batch files must have an extension of .bat or .cmd, not .bak.
 
Back
Top