Importing CSV with line breaks in Excel 2007

前端 未结 23 2266
悲哀的现实
悲哀的现实 2020-11-29 20:49

I\'m working on a feature to export search results to a CSV file to be opened in Excel. One of the fields is a free-text field, which may contain line breaks, commas, quota

23条回答
  •  一个人的身影
    2020-11-29 21:27

    I have finally found the problem!

    It turns out that we were writing the file using Unicode encoding, rather than ASCII or UTF-8. Changing the encoding on the FileStream seems to solve the problem.

    Thanks everyone for all your suggestions!

提交回复
热议问题