Using variables in gmic containing ' Backslashes '

Hello David,

… because… I do not really understand how you got to work that. On my windows-pc it doesn’t work, will add two \…

What I’ve tried:
test:
file=$1
-input file imgPath={0,f} #contains a correct formated windows path imgName={0,b} imgExte={-struncase\ {0,x}} #uncase not realy nessecary in this example… -if {[’$imgExte’]==‘jpg’}

now lets try to add the name of the subfolder…

pTokn1={-struncase\ "out"}\\\ # doesn't work - will add two \\ , well, Windows will acceppt the path this way but... pTokn2={-struncase\ “out\”} # does work - will add one \
pTokn3=out\\ # doesn’t work - same as pTokn1 (by the way: do not use a single \ at the end of a line…)
pTokn4=out\test # strange - a single \ in the middle will be added…
pTokn5=out\$pTokn4 # but cannot be combined with a variable? (double \ or $ escaped…)
-quit

Well - maybe you see what I’m doing wrong - otherwise I will go on with pTokn2… :slight_smile:

Thank you
Thomas