VBA using excel
Posted on 2004-12-01
I am running VB6 with SQL 7 as a backend on OS 2000/office 2002. I use this piece of code to open excel.
Dim oXL As Excel.Application
Dim oWB As Excel.Workbook
Dim oSheet As Excel.Worksheet
Set oXL = CreateObject("Excel.Application")
Set oWB = oXL.Workbooks.Open(lblImportEnrollmentFile.Caption) ' Get a new workbook.
Set oSheet = oWB.ActiveSheet
lngBlankRow = oSheet.Cells.SpecialCells(xlCellTypeLastCell).Row 'Finds first blank row in Column A
I have to distribute my project to a Windows 98 machine using office 97.
when i setup the VB application on the 98 machine i get an error :
"This program has performed an illegal operation and will be shut down. if problem persists, contact the program vendor."
What does this mean? Is there an issue with Excel not being able to open this way.