What's the best way to export UTF8 data into Excel?

前端 未结 8 1491
不思量自难忘°
不思量自难忘° 2020-12-03 03:12

So we have this web app where we support UTF8 data. Hooray UTF8. And we can export the user-supplied data into CSV no problem - it\'s still in UTF8 at that point. The proble

8条回答
  •  离开以前
    2020-12-03 03:24

    I found that if you set the charset encoding of the web page to utf-8, and then Response.BinaryWrite the UTF-8 Byte Order Mark (0xEF 0xBB 0xBF) at the top of the csv file, then Excel 2007 (not sure about other versions) will recognize it as utf-8 and open it correctly.

提交回复
热议问题