Sign in to follow this  
Followers 0
RickB75

Windows Task Scheduler question

5 posts in this topic

Hi guys. I have  a quick question. I have a cmd line to create a scheduled task and to use the user account "SYSTEM". My script can run in the BG with no problem. I'm just wondering If user "A" downloads the compiled .EXE, will the scheduled task still run the .EXE that was downloaded since the scheduled task is set to use the "SYSTEM" account??

Just wondering.

Share this post


Link to post
Share on other sites



Have not tried but if the user account has the correct level of authority why would it not work?  Best bet is to test with something non-destructive...

kylomas


Forum Rules         Procedure for posting code

"I like pigs.  Dogs look up to us.  Cats look down on us.  Pigs treat us as equals."

- Sir Winston Churchill

Share this post


Link to post
Share on other sites

No, sorry, experience level = 0 to none with this kind of thing...


Forum Rules         Procedure for posting code

"I like pigs.  Dogs look up to us.  Cats look down on us.  Pigs treat us as equals."

- Sir Winston Churchill

Share this post


Link to post
Share on other sites

I know this thread is a few month old. I do have another question very similar to this question. I got the task scheduler to work using this line of code. 

RunWait("SCHTASKS /Create /SC DAILY /ST 04:00 /SD 01/29/2015 /TN RicksUpdate /TR " & @ScriptDir & "\Update.exe /RU SYSTEM")

In the last param (/RU SYSTEM), I have it scheduled to run  as a system task. By doing this it allows the exe to run weather the user is logged on or not. On my work PC it works flawless. On my personal though, thats another issue. I'm the admin on my personal pc. When I run this script nothing happens. If I copy the params, open CMD as the Administrator CMD and paste it in, it will schedule the task like it suppose to. 

Using the normal CMD, If I paste it in and remove "/RU SYSTEM", it will also schedule the task but it will not set the param to Run weather the user is logged in or not. It only sets the param to run when the user is logged in. 

 

My question is how can I schedule a task and set it to run weather the user is logged in or not even if they are not the administrator? If I am scheduling a task manually, i can choose that option in the task scheduler UI. 

 

Any Ideas???

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0