Call an Access Macro?

Technical support and scripting issues

Moderators: JRL, Dorian (MJT support)

Post Reply
Dexter1
Pro Scripter
Posts: 64
Joined: Mon Jun 19, 2006 3:28 pm

Call an Access Macro?

Post by Dexter1 » Wed Dec 05, 2007 7:00 pm

I'm trying to open an MS Access database then call a specific macro. I thought I could do it in by using VB within the MacroScheduler macro, but can't seem to get it rolling. Here's the code. At this point I'm just trying to get Access to open:

VBStart
Function Open_MSAccess()
Call Shell ("C:\Program Files\Microsoft Office\OFFICE11\EXCEL.EXE")
End Function

As always, thanks in advance for any help you can give me.
Josh

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Wed Dec 05, 2007 7:21 pm

Hi,

Your macro is trying to open Excel, not Access. Did you mean Access or Excel? Your macro is also using VB code which is not valid VBScript code.

Anyway, if you DID mean Access, here's the solution you are looking for:

http://www.mjtnet.com/forum/viewtopic.php?=&p=15358

If you meant Excel, the above link shows you that too :-)
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

Dexter1
Pro Scripter
Posts: 64
Joined: Mon Jun 19, 2006 3:28 pm

Post by Dexter1 » Wed Dec 05, 2007 7:49 pm

Ah, yes, I did mean Access. I don't know how I ended up with Excel in there.

Thanks!

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts