In WFA i'm trying to display the path to a share so that the person running the workflow can see what the share name will end up being. This share name is generated from other drop downs and fields that are populated. I'm using a sql query to generate a path such as \\somename\blah\blah\Flah. Not the best way of doing it but I see no other option to display to the users what the outcome will be.
When i run the workflow i get the expected error "illegal escape sequence: F". I have tried to create function to escape the \ and add a second \ to produce \\F or for any other character that comes before the backslash but it doesn't work because it errors because it doesn't understand the characters which are fed into it. Java escape characters are limited to these \t,\b,\n,\r,\f,\',\",\\ so if the share name contains any of that it will work...anything fails. Because I can't escape other letters after the backslash such as \F \Z \X it produces an error.
I know I can just produce the second backslash directly from the sql query but then the share name will look irregularly. (\\\\somename\\blah\\blah\\Flah).
Let me know if you have a better idea to try to display the share name.
One other things that I might try but not sure will work because the field will still error would be to create a second unopened/hidden field with the share name using the correct syntax and feed that to the command.
Oddly enough after adding some chars before the \\ and then chopping off the "UNC:" chars for the command input it allows the preview to run green.
I further tied to just leave the \\ at the beginning from the select statement and then tried to chop the \\ chars at the command input but that didn't work. I got the same illegal escape sequence. Very odd behavior.