|
Answer» code:
Code: [SELECT]set hi=hi001 set "^=escapeOnly" set str1="a^!bcd^!efg^^^^^^^^^^^^^!^^^^^^^^^^^!^^^^^^^^^^!hi^^^^^^^^^!^^^^!^!"
echo ----- original ---- echo !str1!
echo ----- other 4 ----- 2x echo " %str1%
output:
Code: [Select]----- original ---- "a!bcd!efg^^^^^^!^^^^^!^^^^^^^escapeOnly "
----- other 4 ----- 2x " "aefg^!^^escapeOnly "
my confusion is in other 4, I tried to do EXPAND and escape operations to build output in my mind, but I can not understand why my code output this.
thanksWhat is your expected output?look at this link: https://www.dostips.com/forum/viewtopic.php?f=3&t=9137
I want to research how the example in link above works when I assign const STRING to variable str1
thanks
|