none
Open Excel in non-compatibility mode RRS feed

  • Question

  • I have written several VB.NET programs that open a new instance of Excel and write data to it. However Excel opens in compatibility mode and this limits the number of rows I can write to it. How do I set it to open in non-compatibility or regular Excel 2007 mode?

     

    Thanks

    Tuesday, May 10, 2011 5:31 PM

Answers

  • If you perform it manually, the setting is in File > Options > Save ( for 2010) or Office > Options > Save (for 2007) and there's a list box for you to set the default format.

    If you perform it programatically at runtime that VB Net command I gave you xl.DefaultSaveFormat = Excel.XlFileFormat.xlOpenXMLWorkbook will do it.


    Regards, Rich
    Tuesday, May 10, 2011 7:23 PM

All replies

  • Save the workbook as "xlsx" format and reopen it, or change the default setting of Excel.

    xl.DefaultSaveFormat = Excel.

    XlFileFormat

    .xlOpenXMLWorkbook


    Regards, Rich
    Tuesday, May 10, 2011 6:56 PM
  • THanks Rich,

    How do I change the default setting in Excel?

    Tuesday, May 10, 2011 7:05 PM
  • If you perform it manually, the setting is in File > Options > Save ( for 2010) or Office > Options > Save (for 2007) and there's a list box for you to set the default format.

    If you perform it programatically at runtime that VB Net command I gave you xl.DefaultSaveFormat = Excel.XlFileFormat.xlOpenXMLWorkbook will do it.


    Regards, Rich
    Tuesday, May 10, 2011 7:23 PM