I have an Access Db Module on another computer that contains a Sub Routine I would like to execute from Excel. How can I execute the routine and have it open and run on the host computer from an Excel workbook on my computer? I tried the code below but ran into two problems (1.) It opens the Access DB on my computer instead of the Host (2.) the appAccess.Run command didn't run the sub routine in Access
Code:
Sub RunAccessSub()
Dim appAccess As Access.Application
' Create instance of Access Application object.
Set appAccess = CreateObject("Access.Application")
' Open WizCode database in Microsoft Access window.
appAccess.OpenCurrentDatabase "B:\Documents and Settings\bconner\Desktop\Template Month End Reports v1.2.mdb", False
' Run Sub procedure.
appAccess.Run "MonthEndReports"
Set appAccess = Nothing
End Sub