comma in string replacement token

I've encountered an issue when using Copy File component and supplying the Source or Destination file path as a string replacement token.  When a filename contains a comma the comma seems to be interpreted as a break during substitution.  For example if a file name is "Test file, 2.txt" then the copy file component throws an error that file 'Test file' cannot be found.  The attached protocol has an example.

Is it possible to escape the comma in the global variable or string replacement token?  I tried adding quotes around the token in the Source parameter field but they get removed.

Thanks

Answers 4
KB
KB 2013-07-19

Put the quotes in the value of the global itself. E.g.

@filename := '"Test file, 2.txt"';

Best Regards,

Keith

GM
GM 2013-07-19

Perfect! Thanks Keith.

Alternatively, I noticed that if you change the parameter type of Source parameter from URLType to StringType then quotes can be added around the string replacement token in the parameter field.

XF
XF 2014-04-03

I figured it out by using binary reader + binary writer instead of copy file component.

XF
XF 2014-04-03

Hi Keith,

I do have the same issue, and the quotes does not help if the file is on SharePoint server.

'"http://myserver.com/sites/shared documents/step 1, 2, 3 and 4.pdf"'

Unknown URL type in path name: "http://myserver.com/sites/shared documents/step 1, 2, 3 and 4.pdf"'

Any ideas?

Thank you.