Opening XLSM RRS feed

  • Question

  • Hello folks,

    I hope that this is going to an question to answer.

    I have a simple VB.net code that opens excel files. It works fine except that when I try to open an Excel 2007 file it opens it in EXCEL 2003 compatibility mode eventhough I have Excel 2007 installed.

    One thing to know is that I have Excel 2007 and Excel 2003 installed (I really need both version) and they work fine and I can open both versions when I want to. The problem is that the Vb.net code that seems to only want to open them all in Excel 203 versin.  Here is part of the code. The program will open the "AC_Template_V3.xlsm" file but in Excel 2003 which will only display only ~ 65000 rows instead of the ~1040800

    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
            Dim exp, wafer, name As String
            Dim oExcel As Object
            On Error GoTo 10
            exp = TextBox1.Text
            wafer = TextBox2.Text
            oExcel = CreateObject("Excel.Application")
            If ComboBox1.Text = "Reliability Summary" Then
                oExcel.Workbooks.Open("\\Givott01\groupiv\FTP Dropbox\Carl\Mark\Templates\AC_Template_V3.xlsm")
    10: Exit Sub
    End Sub



    Friday, March 26, 2010 4:44 PM


All replies