Vista - Standard user needs to run ATI Tasks without admin password - how?

Discussion in 'Acronis True Image Product Line' started by tuttle, Jun 17, 2008.

Thread Status:
Not open for further replies.
  1. tuttle

    tuttle Registered Member

    Joined:
    Mar 5, 2005
    Posts:
    376
    I had a thought that maybe in the SYSTEM task I could create an Action to run another separate task, with Standard user as user, that in turn would run CCleaner. It didn't work. It seems that a task cannot run another task.
     
  2. K0LO

    K0LO Registered Member

    Joined:
    Mar 9, 2006
    Posts:
    2,591
    Location:
    State College, Pennsylvania
    You're a genius! That seems to work. I tried this in my standard user account:

    1. Create a new task as the standard user called "message" and for the user, choose the desired standard user's account name.
    2. For the action choose "Display a message" and then enter the desired message text.
    3. Edit your backup task by starting Task Scheduler as an administrator
    4. Add a second action after the backup action. Choose "Run a program".
    5. For the program to run, enter "schtasks". For the arguments enter "/run /tn message"
    6. Save and exit.
    7. Test as standard user.

    I had always wanted to be able to cascade tasks but didn't know how to. This appears to do the trick - one task can start another task by starting the second task from the command prompt. I suppose that you can cascade these to any desired level. Each task can have the desired user credentials for it to run in the proper context.

    Let me know if this works for you also. Nice suggestion!
     
  3. tuttle

    tuttle Registered Member

    Joined:
    Mar 5, 2005
    Posts:
    376
    Gee, I was a genius and I didn't even know it. o_O I had tested exactly that, and it didn't work. I didn't delete my failed chained tasks test though, and now that I've rebooted they work!

    I on some of the earlier testing that new Task Scheduler tasks did not always run until after a reboot. I concluded that some things had failed, only to discover later that they worked after I had rebooted a few times.
     
  4. K0LO

    K0LO Registered Member

    Joined:
    Mar 9, 2006
    Posts:
    2,591
    Location:
    State College, Pennsylvania
    What might have happened is that, during testing, a task started but did not terminate properly, so it remained in the running state. Rebooting fixes that, of course. I think you can avoid a reboot by pressing the "End" button to force the failed task to finish up. You can confirm this by looking at the "Status" column in Task Manager, which will say "Ready" when the task exits properly.

    I ended up getting tasks "stuck" like this several times while testing. A good way to do that is to use the user name "Users" to run the message task. This displays the message on the screen of every user account on the machine. The task will continue to run until every user presses the "OK" button to acknowledge the message and dismiss the dialog box. Oops; bad idea.
     
  5. tuttle

    tuttle Registered Member

    Joined:
    Mar 5, 2005
    Posts:
    376
    Yeah, I suspected that, so I explicitly Ended each task. I still got failures on some tasks, unit I rebooted and logged into the other profile. I don't know if this quirkiness is shared by other Vista flavours, but I do know there is an annoying bug specific to the Task Scheduler in Home Premium which I have not yet documented.
     
  6. tuttle

    tuttle Registered Member

    Joined:
    Mar 5, 2005
    Posts:
    376
    I'll test this tomorrow. If it works consistently, it has opened up a whole new range of possibilities for chains of tasks even where they mix user elevelation with hetertogeneous privileges and users.

    Now I need to find out if those Task Sheduler-sent messages can be given focus, so that they appear in front of other windows rather than hidden behind windows as they do now. Is there any way to send a message that would display an icon in the Notification Area (if the message would otherwise be hidden behind other windows)?
     
  7. K0LO

    K0LO Registered Member

    Joined:
    Mar 9, 2006
    Posts:
    2,591
    Location:
    State College, Pennsylvania
    Ironically, allowing applications to pop up a window or a dialog box and steal focus from the currently-active window was a major gripe with Windows XP and one of the changes made in Vista. The default behavior is that dialog boxes and popups must never steal focus from a running application. Unless there's a way to program around this, I think you are fighting city hall.

    Probably, but you're getting into the realm of Windows application programming, about which I know nothing.

    How about playing a .wav file at the end of the backup task?
     
  8. tuttle

    tuttle Registered Member

    Joined:
    Mar 5, 2005
    Posts:
    376
    You know, there are many nice touches in Vista that I'm just beginning to discover. For example, in Task Scheduler when creating an Action to Run a program, there is a field in which to enter the path to the executable, and a separate field in which to enter any arguments. I simply paste the entire string, including executable and arguments, into that first field, e.g.

    The Task Scheduler automatically recognizes the arguments portion and separates it into the correct field, and then alerts me to tell me what it intends to do and requests confirmation. Nice.

    This cascading task techique works great. That the SYSTEM can run those things, such as ATI imaging and Defrag, that the Standard user cannot run himself. The cascading then allows that task to run tasks that are actually run by the Standard user for things like CCleaner or messages or GUI events that either can't be run by SYSTEM or for which SYSTEM lacks required information.

    I now have a simple shortcut that my friend will use that will:
    1. Run CCleaner silently.
    2. Defrag C-drive.
    3. Use Acronis to create a Full backup image to an external drive.
    The only drawback is that there is no visual indication when defragging runs, because Vista's Defrag doesn't display progress or any Notification Area icon. I may tell the user to assume that things are still running unless he sees a completion message, and I'll add a task to display such a message or a sound as you suggested. Or, I could add a new action to run a command line to automatically shutdown the PC after the task has completed. If the laptop is off, he'd know that the process was finished.
     
    Last edited: Jun 26, 2008
  9. K0LO

    K0LO Registered Member

    Joined:
    Mar 9, 2006
    Posts:
    2,591
    Location:
    State College, Pennsylvania
    Very nice. Looks like you have achieved most of your objectives. This has been a very worthwhile exercise discovering the ins and outs of Task Scheduler.

    You might consider skipping step 2 - defrag. Take a look at the automatic scheduled task in Vista Task Scheduler (Task Scheduler Library > Microsoft > Defrag) which is by default set up to start a defrag once weekly but only when the PC has been idle for 3 minutes, and to interrupt it if the PC becomes not-idle. You can also edit the parameters of this task if they don't fit your friend's computing habits. This might avoid the need to wait for the task to finish - just let the automatic defrag work silently whenever the PC is idle.

    You're right about the little UI improvements in Vista. Another of my favorites is to observe what happens when you click on a file, and then click again to edit the file name. For example let's say you have a file called "Backup.tib". In Windows XP if you click on this file name to edit, the whole name is selected. So you type a new name but forget to type the extension and end up with "Backup1" for the new name. Now you have to go back and do it again to change it to "Backup1.tib". Vista recognizes that most of the time you only want to change the name but not the extension so it only selects the "Backup" part of the name. You type the new name and the extension remains as before.

    I'm also sorry to see Vista get such bad press. My 3-yr old run-of-the-mill desktop PCs run so much better on Vista than they ever did on XP.
     
  10. tuttle

    tuttle Registered Member

    Joined:
    Mar 5, 2005
    Posts:
    376
    Yeah, I had been considering removing the manual Defrag and just depending upon the scheduled one. I guess it's a holdover from older OS when defrag sucked so much resources that it made it difficult to use the system during defragging.

    You've convinced me. I've removed that action and just modified the trigger time for the scheduled defrag. Thanks.
     
Thread Status:
Not open for further replies.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.