Activity "Write CSV" saves the file in the format of?


#1

Vikasreddy Vicky
August 18, 2016 17:55 ANSWERED
whether write CSV activity saves the excel in the form of CSV(comma delimited) or CSV(MS DOS) ?

and also can you please suggest how can I convert an excel file which is saved with the activity “Write CSV” to encoding as UTF-8 ?


#2

Andrzej.Kniola August 19, 2016 11:57
Hi Vicky,

Best way is to always test. Here is a nice PS script to check the encoding. Without doing that - if I remeber correctly it’s ASCII.

Sidenote - it doesn’t save the excel, but a datatable. Saving as excel is different (uses Interop instead).

The WriteCSV activity does not support supplying an encoding parameter. You will need to roll your own activity/class/extension method (or make a workflow for it, but the compiled code will be faster and more memory efficient).

Here on SO are some examples (in C#), as well as here on MSDN is the WriteAllText overload I’d use (notice the Encoding parameter).

Regards.