Электронная таблица все еще отображается, но с предупреждающим сообщением. Проблема, похоже, происходит потому, что Excel 2007 более придирчив к форматам, соответствующим их расширениям, чем более ранние версии Excel.
Проблема была первоначально обнаружена программой ASP.Net и вызывается в ошибке Excel "Файл, который вы пытаетесь открыть," Spreadsheet.aspx-18.xls ", находится в другом формате, чем указано в расширении файла, Verify...".Однако, когда я открываю файл, он отображается просто отлично. Я использую Excel 2007. Firefox идентифицирует файл как лист Excel 97-2003.
Вот страница ASP.NET, которая создает проблему:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Spreadsheet.aspx.cs" Inherits="Spreadsheet" %>
Код за файлом выглядит следующим образом:
public partial class Spreadsheet : System.Web.UI.Page {
protected void Page_Load(object sender, EventArgs e)
{
Response.ContentType = "application/vnd.ms-excel";
Response.Clear();
Response.Write("Field\tValue\tCount\n");
Response.Write("Coin\tPenny\t443\n");
Response.Write("Coin\tNickel\t99\n");
}
}
Т