Exporting a csv file containing Portuguese characters gets mangled when opened in excel
posted 4 years ago
Our application allows the user to export some data with to a csv file. I am writing to a string bullder and using .toString.getBytes("UTF-8") and sending those bytes to the response's output stream. If the user imports it into Excel, characters with tildes, cedillas, etc. show up fine, but if the user double-clicks the file, those characters are replaced with other characters. Is there any way to make this work for both Mac and Windows or at least Windows?