EndFunc Posted November 21, 2014 Share Posted November 21, 2014 I'm pulling my hair out. This is one of the most problematic things for me is escaping commandline stuff with autoit. Anyway, I keep trying to run this command for back up scheduling and it doesn't recognize my quotes. Unfortunately the path has a space. What exactly am I doing wrong? $iSched = RunWait(@ComSpec & ' /k ' & '"D:\program files\tivoli\tsm\baclient\dsmcutil" inst scheduler /name:"ADSM Scheduler" /node:' & @ComputerName & ' /clientdir:"D:\Program Files\Tivoli\TSM\baclient" /optfile:"D:\program files\tivoli\tsm\baclient\dsm.opt" /password:' & @ComputerName & ' /validate:yes /autostart:yes /startnow:yes', "", @SW_SHOW) I get this error. 'D:program' is not recognized as an internal or external command, operable program or batch file. EndFuncAutoIt is the shiznit. I love it. Link to comment Share on other sites More sharing options...
EndFunc Posted November 21, 2014 Author Share Posted November 21, 2014 (edited) Nevermind I was able to get it to work using the "Working directory" parameter of runwait. $iSched = RunWait(@ComSpec & ' /k ' & 'dsmcutil.exe inst scheduler /name:"ADSM Scheduler" /node:' & @ComputerName & ' /clientdir:"D:\Program Files\Tivoli\TSM\baclient" /optfile:"D:\program files\tivoli\tsm\baclient\dsm.opt" /password:' & @ComputerName & ' /validate:yes /autostart:yes /startnow:yes', "D:\program files\tivoli\tsm\baclient", @SW_SHOW) Edited November 21, 2014 by EndFunc EndFuncAutoIt is the shiznit. I love it. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now