O$ 10.0 Export to file on windows is unicode
Paul Mulroney
pmulroney at logicaldevelopments.com.au
Thu May 27 01:32:09 UTC 2021
Hi $all,
I've got a weird one. I'm exporting a file to disk, and then later it's being downloaded in the jsClient. When I'm testing on my mac, it downloads the tab-delimited file as ASCII UTF-8, no problems. Run the same in production on windows server, and it's downloaded as UTF-8 with BOM. This causes problems when I try to open the file in Excel. The file also has CR/LF when exporting from a windows platform, and only a CR when exporting from the Mac.
Can I make it so that it always exports with CR/LF, regardless of platform?
It's running a multi-threaded server, I'm wondering if that's causing a problem with the unicode export?
Here's the code in the startup task:
> Do $root.$prefs.$exportencoding.$assign(kUniTypeUTF8) ## Export as UTF-8 (ie ASCII)
> Do $root.$prefs.$exportbom.$assign(kFalse) ## Turn off export Byte Order Marker in the export file.
Here's the basic code that generates the export file.
> Set print or export file name [vsPathName]
> Prepare for export to file Delimited (tabs)
> Export data vlExport
> End export
> Close print or export file
What am I missing?
Regards,
Paul.
An invisible man married an invisible woman. The kids were nothing to look at either.
--
Paul W. Mulroney We Don't Do Simple Pty Ltd
pmulroney at logicaldevelopments.com.au Trading as Logical Developments
www.logicaldevelopments.com.au ACN 161 009 374
Ph: +61 8 9458 3889 86 Coolgardie Street
BENTLEY WA 6102
More information about the omnisdev-en
mailing list