Quantcast
Channel: Active questions tagged utf-8 - Stack Overflow
Viewing all articles
Browse latest Browse all 1142

CSV with semicolon separator and special characters such as é [closed]

$
0
0

I need to save a UTF8-encoded CSV from Excel, using ; (semicolon) as a separator. I can do this manually or programmatically using ADODB.Stream.

The CSV includes some special characters, such as é.

I'd like to be able to open the CSV in Excel after creating it. However, to do this easily (without having to import and choose the separator), it's necessary (I think) to add a new line to the top of the CSV as follows:

sep=;

But, when I do that and then open the file in Excel, although the field separation is correct, the special characters get screwed up. I can open it in Notepad and the characters are fine. It's just in Excel where they look bad.

As an example, a CSV without the sep=; line might show this data:

Comédia

Whereas a CSV with the sep=; line would show this for the same data:

Comédia

Do you know if there is a solution where I can include the sep=; line but also have the characters display correctly upon opening in Excel?


Viewing all articles
Browse latest Browse all 1142

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>