Issue while opening the Excel file in I.E Browser


I created the spreadsheet withe following code.
public static void ProcessRequest(string xml, HttpContext context)

        var writer = new ExcelWriter();

        context.Response.ContentType = writer.ContentType;
        context.Response.HeaderEncoding = System.Text.Encoding.UTF8;
        context.Response.AppendHeader("Content-Disposition", "attachment;filename=excel.xlsx");
        context.Response.AppendHeader("Cache-Control", "max-age=0");

        var formattedxml = context.Server.UrlDecode(xml);

        var stream = writer.Generate(formattedxml);


i am getting an error when we open a execl generated from above code in Internet explore browser
excel canot be open “.xlsx” because file format or extention is not valide.

But if i use the same code and generate the excel file by using chrome browser. i manage to open file without error.

please suggest for same.

we couldn’t reproduce the issue or our samples, what version of ie do you use?
You may try latest dev version …
if issue still appears there, please attach complete demo, where we could test it