What are the ERRORLEVEL values set by internal cmd.exe commands?

In this answer the ERRORLEVEL values returned by all internal cmd.exe commands are described; they are grouped by the way the value is changed and presented as quick reference tables. I reviewed other similar tables in order to assemble this one, but filled the missing values via tests performed in a Windows 8.1 computer. I … Read more

How to return an error code without closing the Command Prompt window?

To get help for command prompt commands use their /? option. Exit /? shows: Quits the CMD.EXE program (command interpreter) or the current batch script. EXIT [/B] [exitCode] /B specifies to exit the current batch script instead of CMD.EXE. If executed from outside a batch script, it will quit CMD.EXE exitCode specifies a numeric number. … Read more

Do Batch files support multiline variables

Or you can create a “real” newline character. setlocal enableDelayedExpansion set NL=^ rem two empty line required echo first line !NL! second line set multi=Line1!NL!Line2 set multi=!multi!!NL!Line3 echo !Multi! With this variant the newline is a “normal” character in the string, so the variables act normally and you can assign them to another variable, this … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)