0 Replies Latest reply on Jan 19, 2012 8:02 AM by Murshed1992

    Exporting to Excel: How do I keep the data in Unicode and not change encoding once it gets to Excel?

    Murshed1992

      I've got a datagrid that someone added an "Export to Excel" option to. When users click the option to do so, the data goes and opens up in a spread sheet all well and fine. But, the data leaves the Datagrid as Unicode (UTF-8) character encoded and is interpreted using one of the ISO-5589 encodings in Excel. What results is certain characters not rendering properly. For example a dash (longer than a standard hyphen) is magically transformed into these three characters: â€". There doesn't seem to be a way to change encoding while viewing the spread-sheet which would be nice.

       

      One unwieldy solution to this was to save the data as a CSV once its in Excel and re-import the CSV file while explicitly setting encoding to UTF-8 in the Import Wizard. This corrects the issue (that is, the characters go back to normal), but is too cumbersome to do every time you need it. Any suggestions on how I can keep the integrity of the characters during transport?