Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
JT,
In Excel, you would use this to run a macro from another workbook: Application.Run "'Workbook Name.xls'!Macro_Name" so, and I'm just guessing here, something along the lines of AppAcc.DoCmd.RunMacro "'" & vName & "'!Import_AR_Data" You might want to post in an Access group.... HTH, Bernie MS Excel MVP "JT" wrote in message ... I am opening an Access Database from Excel.....so far no problem.......once I get the database opened.....I want the macro to run a macro I have stored in Access. Here is the code I'm using: Set AppAcc = New Access.Application AppAcc.Visible = True AppAcc.OpenCurrentDatabase vName AppAcc.DoCmd.RunMacro ("Import_AR_Data") When the macro gets to this last line of code, I get the following message: Microsoft Office Access can't find the macro 'Import_AR_Data' (This Access macro will run several queries in vba from Access) It is in the database in a module called "Import_ARs" Any suggestions on what I am doing wrong would be greatly appreciated. Thanks for all of the help. -- JT |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Counting instances of found text (Excel error? Or user error?) | Excel Worksheet Functions | |||
Error Handling - On Error GoTo doesn't trap error successfully | Excel Programming | |||
run-time error '1004': Application-defined or object-deifined error | Excel Programming | |||
Automation Error, Unknown Error. Error value - 440 | Excel Programming |