E
Eric
I am having some trouble getting this code to work for my
Access to Excel Automation. I have my refrences set to
Excel 97 (in Access 97) but the following code doesn't
work. It's pretty self-explainitory.
Public Function AuditSummary()
On Error GoTo ErrorHandler
Dim objExcel As Excel.Application
Dim msg1 As String, msg2 As String, msg3 As String
Set objExcel = Excel.Application
objExcel.Sheets("AuditSummary").Select
Range("B3").Value = "Leola"
Range("C3").Value = "04/05/2004"
objExcel.Worksheets("SummaryComparison").Activate
Range("B3").Value = "Leola"
Range("C3").Value = "04/05/2004"
'Rest of code goes here...which works.
End Sub
I am having issues with objExcel.Sheets
("AuditSummary").Select in which I get a 1004 run time
error. I'm sure that I am missing something simple, but I
am getting frustrated.
Any help is greatly appreciated.
Access to Excel Automation. I have my refrences set to
Excel 97 (in Access 97) but the following code doesn't
work. It's pretty self-explainitory.
Public Function AuditSummary()
On Error GoTo ErrorHandler
Dim objExcel As Excel.Application
Dim msg1 As String, msg2 As String, msg3 As String
Set objExcel = Excel.Application
objExcel.Sheets("AuditSummary").Select
Range("B3").Value = "Leola"
Range("C3").Value = "04/05/2004"
objExcel.Worksheets("SummaryComparison").Activate
Range("B3").Value = "Leola"
Range("C3").Value = "04/05/2004"
'Rest of code goes here...which works.
End Sub
I am having issues with objExcel.Sheets
("AuditSummary").Select in which I get a 1004 run time
error. I'm sure that I am missing something simple, but I
am getting frustrated.
Any help is greatly appreciated.