Page 1 of 1

Encoding cvs file with UTF8 with BOM

Posted: Wed Dec 17, 2014 4:07 am
by JackBroughton
Hi All,

I have been asked to export some data from my system into a cvs file with UTF8 w BOM Encodeing.

I have read a stack on uniencode and have I currently have it exporting with UTF8 but it does not have the BOM encoding.

Can anyone help me with this issue?

Thanks, Jack

Re: Encoding cvs file with UTF8 with BOM

Posted: Fri Dec 19, 2014 4:53 pm
by MaxV
BOM for UTF-8 are three byte: EF BB BF

EE = 238
BB = 187
BF = 191

so just:

Code: Select all

put numtoByte(238) & numtoByte(187) & numtoByte(191) before myText 
put mytext into URL "binfile:./mytext.txt"