Hi Guys & Gals,
i'm trying to use Excel VBA to create schedule tasks.
I'm using a very simple macro to test it
The selection at the time is the commands for CMD SCHTASKS in one complete string
the screen flickers (it actually works)
but nothing is created.
ive typed it in manually i get an error
the is currently an addin that does all this already. but i want to do it in Bulk (50-70 tasks)
can anyone please help me???
i'm trying to use Excel VBA to create schedule tasks.
I'm using a very simple macro to test it
Code:
Sub Test()
Shell (Selection.Value)
End Sub
The selection at the time is the commands for CMD SCHTASKS in one complete string
Code:
SCHTASKS /S \\RemoteCompName /U MYDOMAIN\MYUSERNAME /P MYPASSWORD /RU MYDOMAIN\RemoteCompUser /RP RemoteCompPassword /SC WEEKLY /D MON,TUE,WED,THU,FRI /M JAN, FEB, MAR,APR, MAY, JUN, JUL, AUG, SEP, OCT,NOV, DEC /TN Back Order (Sales) - 100
/TR "C:\Program Files\JetReports\autopilot.exe" /m "Update" /I \\QCSVR01\QuickCorporate$\Quick Corporate\Forms\Backup_Forms\Jet - Sales and Marketing\Back Order (Sales).xls /O "\\QCSVR01\QuickCorporate$\Quick Corporate\Forms\Jet - Sales And Marketing\Back Order\Rep 100\%YEAR%\%MONTH%\Back Order - 100 %DAY%-%MONTH%-%YEAR%.xls /L \\QCSVR01\QuickCorporate$\Quick Corporate\Forms\Daily Schedule Log.txt /e aaa@mail.com;bbb@mail.com /P "Acct_Mngr" "100"
/ST 21:02:00 /SD "01/01/2009"
the screen flickers (it actually works)
but nothing is created.
ive typed it in manually i get an error
Code:
ERROR: Length of the command line argument should not exceed 255 characters.
the is currently an addin that does all this already. but i want to do it in Bulk (50-70 tasks)
can anyone please help me???