VB Excel Automation Error "ActiveX component can't create object"
Posted on 2003-11-11
I am getting the following error message
Run-time Error 429 ActiveX component can't create object
Dim sSQL As String
Dim rRS As ADODB.Recordset
Dim oExcel As Object ' Excel application
Dim oWorkBook As Object ' Excel workbook
Dim oSheet As Object ' Excel Worksheet
Dim oChart As Object ' Excel Chart
Dim iCount As Integer
Dim commonDialog As Object
Dim iTop As Integer
Dim sPreviousDay As String
Dim iFirstDay As Integer
Dim iChartNumber As Integer
Set oExcel = CreateObject("Excel.Application")
Set oWorkBook = oExcel.Workbooks.Add
Set oSheet = oWorkBook.Worksheets.Item(1)
oSheet.Name = "Web Tracking"
This is how i am creating the excel document.
I have read many articles about refernces etc, but non seem to work.
It works fine on my PC, but not on other peoples.