Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
tech-notes:scripts:top-tips [2019/03/05 13:49] – [echo without a new line - e.g. use "." to show progress in a loop] gerardorourketech-notes:scripts:top-tips [2019/03/05 14:12] (current) – [ENABLEDELAYEDEXPANSION] gerardorourke
Line 3: Line 3:
 ==== echo without a new line - e.g. use "." to show progress in a loop ==== ==== echo without a new line - e.g. use "." to show progress in a loop ====
 <code cmd> <code cmd>
-echo | set/p=.+echo | set /p=.
 </code> </code>
  
 +==== ENABLEDELAYEDEXPANSION ====
 +Use in FOR loops to get variable as it is set there (rather than a parse time) - need to use !var! rather than %var% 
 +Google it!
 +But any scripts with a ! get messed up!
 +
 +<code cmd>
 +SETLOCAL ENABLEDELAYEDEXPANSION
 +SETLOCAL DisableDelayedExpansion
 +</code>
  • tech-notes/scripts/top-tips.1551793743.txt.gz
  • Last modified: 2019/03/05 13:49
  • by gerardorourke