anorakgirl
Programmer
I am stuck trying to write a bat file.
the command i need to run is this:
This works fine on its own in a bat file. But, the cmd window stays open until the access database is closed, which is bothering my users.
I read somewhere that running a command like this:
start /d "MyCommand" would then close the window, but I can't get this to work I think because of all the quotes already in my command.
For example, if I do
I get "invalid switch - /wrkgrp"
And I can't see how to put quotes around it all cos of the quotes already there. It really needs to work on XP and 2000 as well...
So, any suggestions gratefully appreciated.
Thanks!
~ ~
the command i need to run is this:
Code:
"C:\Program Files\Microsoft Office\Office\MSACCESS.EXE" "%userprofile%\Desktop\myDb.mde" /wrkgrp \\MyServer\myWorkGroup.mdw
This works fine on its own in a bat file. But, the cmd window stays open until the access database is closed, which is bothering my users.
I read somewhere that running a command like this:
start /d "MyCommand" would then close the window, but I can't get this to work I think because of all the quotes already in my command.
For example, if I do
Code:
start /d "C:\Program Files\Microsoft Office\Office\MSACCESS.EXE" "%userprofile%\Desktop\mt_ops.mde" /wrkgrp \\myServer\myWorkGroup.mdw
I get "invalid switch - /wrkgrp"
And I can't see how to put quotes around it all cos of the quotes already there. It really needs to work on XP and 2000 as well...
So, any suggestions gratefully appreciated.
Thanks!
~ ~