What are the differences between .bat and .cmd?

7

We rarely see .cmd , but when we open it, we see that its contents are very close to .bat .

  • What is the reason for this similarity?
  • What would be the main differences between them?
asked by anonymous 05.04.2018 / 14:43

1 answer

5

The only difference between .cmd and .bat , is that in .cmd the variable ERRORLEVEL ( PATH / APPEND / PROMPT / SET / ASSOC ) is also supported in the case of successful commands affected by command extensions .

In% w / w%, variable% w / w% will only change in case of an error.

Font

    
05.04.2018 / 16:02