View unanswered posts | View active topics It is currently 21 Aug 2014 02:12



Post new topic Reply to topic  [ 3 posts ] 
Executing multiple macros without quitting the application 
Author Message

Joined: 17 Jul 2012 07:58
Posts: 2
Post Executing multiple macros without quitting the application
Hello all.

I have very limited experience with writing .bat files. However, I wrote this very simple batch file which executes two Access macros:
Code:
C:
CD \Program Files (x86)\Microsoft Office\Office14
MSACCESS.EXE "C:\...\Databases\final\file.accdb" /X test1
MSACCESS.EXE "C:\...\Databases\final\file.accdb" /X test2
pause
CD \
EXIT

The code executes fine, but requires me to add a "QuitAccess" line to the macros. If I don't, then the first macro will run (test1), but after that nothing will happen. Now in this example there are only 2 macros, but there are cases where I need to run much more macros. In such cases it is very weird to keep shutting down access after the execution of each macro, to be able to run the next one.

Of course I could solve this by creating macros which combine other macros within Access, but I really hope there is a solution to this through programming within the batch file. Of course I already searched the web for a solution, but unfortunately without result. I would be grateful if anyone could direct me to a possible way to solve this issue.

With kind regards
Fantast~


17 Jul 2012 08:12
Profile

Joined: 23 Dec 2011 13:59
Posts: 1790
Post Re: Executing multiple macros without quitting the applicati
I would say your best bet is to create a macro that calls the other macros.


17 Jul 2012 14:49
Profile

Joined: 17 Jul 2012 07:58
Posts: 2
Post Re: Executing multiple macros without quitting the applicati
@Squashman
That is unfortunate. I guess I have no other option at the moment indeed. Thank you for your input.


18 Jul 2012 02:28
Profile
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 


Who is online

Users browsing this forum: Google [Bot] and 23 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Forum style by Vjacheslav Trushkin for Free Forums/DivisionCore.