Was given a project at work to fix an Excel workbook that pulled info from an Access Macro. The error is a 'Run-Time Error: 7866.' This is the current code and the line with asterisks is the line the debugger highlights:
Sub Macro1()
'
' Macro1 Macro
'
'
Dim A As Object
Application.DisplayAlerts = False
Set A = CreateObject("Access.Application")
A.Visible = False
*A.OpenCurrentDatabase ("H:\Distpatch - Broker Loads Fixed.accdb")*
A.DoCmd.RunMacro "Summarize"
Application.DisplayAlerts = True
ActiveWorkbook.RefreshAll
End Sub
Anyone have any advice or a different code to run this macro?
Thanks.
Bookmarks