Modify ↓
Opened 10 years ago
Closed 10 years ago
#3186 closed Bug (No Bug)
Special characters change after filewrite to *.csv
| Reported by: | snarf | Owned by: | |
|---|---|---|---|
| Milestone: | Component: | AutoIt | |
| Version: | 3.3.14.0 | Severity: | None |
| Keywords: | Special character bug | Cc: |
Description
If you create a csv file, for example TextFile.csv with the characters:
éë
and then do a fileread and filewrite,
$FileContents = FileRead(@ScriptDir & "\TextFile.csv")
FileWrite(@ScriptDir & "\NewFile.csv", $FileContents)
Open the newfile.csv in excel and the characters are changed to éë
This is a real problem, al special characters are changed after a filewrite.
This bug is in all 3.3.14.x versions
Attachments (0)
Note:
See TracTickets
for help on using tickets.

From the helpfile:
When writing text AutoIt will write using UTF8 (without BOM) by default. To write in another mode the file must be opened with FileOpen() and the relevant flags.
So the default has changed and you need to use FileOpen with the appropriate parameters.
Jos