Jump to content

Recommended Posts


Posted

some1,

.bat and .cmd are batch files but .cmd only runs on NT and for 9x you must use .bat

Each version of Windows have their supported command-lines so a .bat or a .cmd may not work on each Windows version. It depends on the features of a specific Windows.

Maybe there is others distinctions but I only know these.

Posted

There are differences that may be irrelevant, or huge, depending on what the script does.

Basically, the .cmd extension is the better choice for Windows NT-based OSes, because the .cmd extension is associated with the cmd.exe program, which uses a native 32-bit command environment. Scripts that use the .bat extension are associated with the 16-bit program command.exe, and they will run in the NT Virtual DOS Machine (NTVDM) instead of the native 32-bit cmd.exe program, which is less reliable than the cmd.exe environment.

Posted

It used to be that .BAT files were passed to command.com to process from the start, while .CMD files are processed from CMD.EXE directly (without loading the NTVDM environment first),

In any case, if you use 4NT to run the files, this distinction is irrelevant (since 4nt processes bat files directly), but you can't use EXTPROC or rexx scripting in BAT files, but you can use these in CMD files.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...