This project has moved and is read-only. For the latest updates, please go here.

Worksheets Incompatible with Excel 2007

Jul 5, 2013 at 5:27 PM

I am using Closed XML to generate Excel reports in VB.NET in the following way:

Dim BinaryData() As Byte = File.ReadAllBytes("myFile.xlsx")
Response.AddHeader("Content-Length", BinaryData.Length - 1)
Response.AppendHeader("Content-Disposition", "attachment; filename=myFile.xlsx")

When I use Excel 2010 to open the file, everything works perfectly.

When I use Excel 2007 to open the file, it opens up with a bunch of gibberish.

Does anyone have any ideas about what might be casuing this?