This content has been marked as final. Show 5 replies
Try escaping the \
find text "barcode" change text "ËU(K\\tÌ"
"\\t" instead of "\t" should work
you need to double every "\"
Unfortunately if you escape the \t or \r you get a single \ with a tab after. Also this is not the only case you also have ^p ^n and the list goes on and on.
I would prefer turning this feature off and back on due to the fact I do use a lot of these features such as ^p and ^n for carriage returns.
You are working in a script language. That translates "\t" to a tab while the script is being parsed, and (apparently) the tab survives the translation into the 'real' application call to search.
Next level is escaping the tab: "\\t". Now the codes get translated (by the parser) into "\t", which is, ta-da, a tab
i for the application search string.
So, you have to escape the escaped escape (?), leading to the somewhat bewildering "\\\\t". Double backslashes are translated into single ones ("\\t") which is passed over to the search inside InDesign, which translates it into "\t", which is what you asked.
The "^" is slightly easier, as it (probably!) is not 'pre-parsed' by your script, just by the InDesign Search engine. As in InDesign itself, to search for a single "^", enter two.
By the way ... there is no single search string in which both "\t"
"^p" are translated into a tab and paragraph return. The former is a GREP search expression, the latter a native InDesign Text search one.
Just to give some background I am using AppleScript and UT-8 XML so I can get the string to InDesign with out issues.
So to test I was using the InDesign interface and doing a manual find and change. If you use a grep express and put \\t you will get a \ with a tab after. I will say it was confusing the way I explained the issue because I had two different things going on at once.
The first problem I ran into was with ^p using change text so to fix this I went to change grep. By doing this I fixed one problem and created another. I see now I can use change text and double up on the ^ and the problem should be resolved.
thanks for the help