Parsing Shell Command with Parenthesis

G

GarethG

This is how I would execute the following in a .BAT file:

"N:\Apps\Opera Reports\Office\MSACCESS.EXE" K:\ExpCurMonth.mdb /x
"Autorun"

However, if I try to use
Shell("<Above Line>", 0)

in VBA it moans about the ".

For now I just call the .Bat file, but the zero hides the command
prompt window and not the Access window.

I want to run the above command line and also hide the Access window
using zero in the shell command.

Any takers?
 
T

Tom Ogilvy

"N:\Apps\Opera Reports\Office\MSACCESS.EXE K:\ExpCurMonth.mdb /x
""Autorun"""

Would be my guess although I don't know why autorun would need to be in
quotes. If not, you can try:

"N:\Apps\Opera Reports\Office\MSACCESS.EXE K:\ExpCurMonth.mdb /x Autorun"

Adjust spacing for the /x Autorun to what it should be - it word wrapped in
your email, so I don't know what it should be.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top