Open XML – OLE Automation Date Issues
If you are exporting a date from C# to Excel using 2007, you probably will use the following:
This exports the date as a OLE Automation date recognized by Excel 2007. How ever, in Excel 2010 this was causing issues, every time I exported to Excel 2010, it said that it has to repair my document and it never displayed the values correctly as dates.
Because I was using Open XML to generate the markup, Excel 2010 has been support for Open XML. I got around the problem of using:
This exports the date as a XML Date format.
Hope this helps anyone who has the same problem!
1 Comment
Leave a Reply
You must be logged in to post a comment.



[...] This post was mentioned on Twitter by Ken Eldridge, Tim Brown. Tim Brown said: Blog Post: Open XML – OLE Automation Date Issues http://blog.codelab.co.nz/2010/07/26/open-xml-ole-automation-date-issues/ [...]