Welcome to the Xceed Community | Help
Community Search  
More Search Options

.xls files exported using ExportToExcel give "different format" warning when open in Excel 2007

Sort Posts: Previous Next
  •  03-09-2010, 8:42 PM Post no. 26048

    .xls files exported using ExportToExcel give "different format" warning when open in Excel 2007

    When I try to open a file in Excel 2007 that has been exported using the ExportToExcel() function on a DataGrid, I get a message:

    "The file you are trying to open, 'filename.xls', is in a different format than specified by the file extension. Verify that the file is not corrupted and is from a trusted source before opening the file. Do you want to open the file now?"

    If I press 'Yes', it opens fine.  This didn't happen in Excel 2003.  Is there a fix for this?


    Associate, .NET Development
    Morgan Stanley, UK
    Filed under: ,
  •  03-10-2010, 1:52 AM Post no. 26049 in reply to 26048

    Re: .xls files exported using ExportToExcel give "different format" warning when open in Excel 2007

    This post shoudl explain all... http://xceed.com/CS/forums/post/24984.aspx

    The export is in xml format - hence the warning message. If you name your export file blah.xml then the message will not be displayed.

  •  03-10-2010, 9:04 AM Post no. 26054 in reply to 26049

    Re: .xls files exported using ExportToExcel give "different format" warning when open in Excel 2007

    Ah thanks. I did search for an answer using the search string "different format than specified by the file extension", but it didn't come up with the existing post because that post has typos in it for that same error message.  Emphasises the importance of spelling error messages correctly!

    Thanks for your help.

    Jason


    Associate, .NET Development
    Morgan Stanley, UK
View as RSS news feed in XML
Contact | Site Map | Reviews | Legal Terms of Use | Trademarks | Privacy Statement Copyright 2011 Xceed Software Inc.