Dear readers,
A strange thing occurs today. In an an AttributeManager, I changed the value of an output attribute, from a fixed string to using a user parameter, partly.
The original string was:
mkdir "Y:\\Basis\\Kunstwerken\\@Value(KWK)\\@Value(KW_CODE)"
I substituted the part in bold with a user parameter (in bold, too):
mkdir "$(Kunstwerkmappen)\\@Value(KWK)\\@Value(KW_CODE)"
Now, here's the funny thing. If I provide the user parameter with the original string, the result is (one record as an example):
copy "I:\\BEHEER\\Temp\\Ferdinand\\LM_fotos\\Pictures_LM249DrempelsZestienhoven\\061720122651.jpg" "Y:\\Basis\\Kunstwerken\\Gemalen\\KGM-231\\061720122651.jpg"
All seems fine. But the idea is to be able to change the value of the user parameter. So I tried filling in "I:\\BEHEER\\Temp\\Ferdinand\\LM_fotos\\Kunstwerken" (without the quotes)
I get this result:
copy "I:\\BEHEER\\Temp\\Ferdinand\\LM_fotos\\Pictures_LM249DrempelsZestienhoven\\061720122651.jpg" "I:\\BEHEER\\Temp\\Ferdinand\\LM_fotos/Kunstwerken\\Gemalen\\KGM-231\\061720122651.jpg"
Notice the backslash in the part "LM_fotos\\Kunstwerken" has changed to "LM_fotos/Kunstwerken"?
It reminds one of string replacement or escape characters. But in both strings, the combination that would matter is the same: s\\K. Changing the name of the directory Kunstwerken to something els doesn't make a difference. And none of the other backslashes are converted either.
So why does this not work the way I expected?
Kind regards,
Ferdinand.
PS: I am unable to reproduce this, but at some point it got worse or, rather, weirder. I got the GUI TEXT content back as part of the result, somewhat like what was reported here to happen in an underlying Python script.
Don't know if that helps pointing in the right direction.