Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.
This is what it looks like:
runwait ("P:\....\TICKETSXMIT1.mdb", "")
There is another way to launch Access and run a macro without using OLE. You must, however, call the MSACCESS.EXE itself, using the following syntax.
D:\APPS\Microsoft_Office\Office10\MSACCESS.EXE YourApp.MDB /WRKGRP SECURED.MDW /user UserID /pwd YourPassword /x macImportCustomersThe /WRKGRP, /user, and /pwd arguments are required only if your application is secured. However, the /x argument is required, as it calls the desired macro.
Note that I used the fully qualified file name, D:\APPS\Microsoft_Office\Office10\MSACCESS.EXE, to the Microsoft Access executable on my system. I didn't actually hard code the path; I used the Win32 FindExecutableA function to locate it. Here is the code:
BuffSize = 512 hBuff = BinaryAlloc ( BuffSize ) ShellLibFQFN = StrCat ( DirWindows ( 1 ) , 'shell32.dll' ) ResultCode = DllCall ( ShellLibFQFN , long:'FindExecutableA' , lpstr:CustomerMasterFQFN , lpstr:DefaultDataDir , lpbinary:hBuff ) If ResultCode < 33, the function failed, most likely because Access is not properly installed. Otherwise, the path is given by the following statement. MSAccessBinary = BinaryPeekStr ( hBuff , 0 , BuffSize )
Article ID: W16596
File Created: 2014:07:18:09:51:38
Last Updated: 2014:07:18:09:51:38