M
Maury Markowitz
I'm calling Excel from Access to run a lengthy report. In order to
ensure I have the correct modules loaded up, I call them explicitly:
Set oExcelApp = GetObject(, "Excel.Application")
If Err <> 0 Then
Set oExcelApp = CreateObject("Excel.Application")
bStarted = True
End If
' make sure that Pricing is open and up to date
If oExcelApp.Workbooks.Count = 0 Or
Len(oExcelApp.Workbooks("Pricing.xla").name) <> 0 Then
ret = oExcelApp.Workbooks.Open("O:\HPL\Addins\Pricing.xla")
End If
oExcelApp.Visible = True
ret = oExcelApp.Run("HPLCreate.xla!BuildHPL",)
This is returning the error in the subject, 1004. The app is visible,
so I go over, view VBA, and sure enough, the module is absolutely
there. Yes, it's public.
Does anyone have a clue why this might be happening?
Maury
ensure I have the correct modules loaded up, I call them explicitly:
Set oExcelApp = GetObject(, "Excel.Application")
If Err <> 0 Then
Set oExcelApp = CreateObject("Excel.Application")
bStarted = True
End If
' make sure that Pricing is open and up to date
If oExcelApp.Workbooks.Count = 0 Or
Len(oExcelApp.Workbooks("Pricing.xla").name) <> 0 Then
ret = oExcelApp.Workbooks.Open("O:\HPL\Addins\Pricing.xla")
End If
oExcelApp.Visible = True
ret = oExcelApp.Run("HPLCreate.xla!BuildHPL",)
This is returning the error in the subject, 1004. The app is visible,
so I go over, view VBA, and sure enough, the module is absolutely
there. Yes, it's public.
Does anyone have a clue why this might be happening?
Maury