Passing around multi-line strings

You can create directly multiline strings with the caret (one empty line is required). setlocal EnableDelayedExpansion set multiLine=This is a ^ multiline text^ line3 echo !multiLine! Or you can create first a newline character. setlocal EnableDelayedExpansion set LF=^ rem Two empty lines are required set multiLine=This is a!LF!multiline text!LF!line3 echo !multiLine! An explanation how this … Read more

Run a shortcut with a batch file

The help for start contains this tidbit: START [“title”] [/D path] [/I] [/MIN] [/MAX] [/SEPARATE | /SHARED] [/LOW | /NORMAL | /HIGH | /REALTIME | /ABOVENORMAL | /BELOWNORMAL] [/NODE <NUMA node>] [/AFFINITY <hex affinity mask>] [/WAIT] [/B] [command/program] [parameters] “title” Title to display in window title bar. In other words the first quoted string will … Read more

Are there any better command prompts for Windows?

2019 Update: Microsoft has released the terminal app on Github & the Windows Store, and it has tabs, panels, acrylic transparency, and other features. 2016 Update: Windows 10’s default conhost UI has more features, including free resize, transparency, etc (this includes cmd & powershell) I now use ConEmu (walkthrough here) which has many features including … Read more

Variables are not behaving as expected

You are not the first, who fell into the famous “delayed expansion trap” (and you won’t be the last). You need delayed expansion if you want to use a variable, that you changed in the same block (a block is a series of commands within parentheses (and )). Delayed variables are referenced with !var! instead … Read more

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