http://www.perlmonks.org?node_id=32219


in reply to How long 'tween now and then?

On Win2k you can schedule things using the scheduler (the GUI version of AT.EXE, which for some dumb reason, is not the same thing.) Open Explorer to your computer and you should see a folder called "Scheduled Tasks" at the same level as the drives. There you can click "add task" and be greated by the schedule wizard. You can browse to your script from there and specify the username to run it under.

I know its not very Perl-ish, but its the most straight forward MS-ish way to do it.

Replies are listed 'Best First'.
RE: RE: How long 'tween now and then?
by myocom (Deacon) on Sep 13, 2000 at 04:34 UTC

    Ah, but that goes against one of the fundamental requirements for this: It must be automated. The Task Scheduler isn't automated (nor does it provide a scriptable interface).

    FWIW, just for the sake of completeness, AT.EXE in Win2K actually adds "special" Scheduled Tasks. If you modify them from Task Scheduler's GUI, they lose their 'AT-ness' (that is, you can no longer manipulate them from AT).

      ooops. Missed the '80 computers' part... :-)

      looking at what passes for documentation for at.exe I don't see anything specifying the user. That's no good. But I do see that you can specify the computername, which makes me wonder... how does AT verify that I have permission to run this program on that other computer? My only guess is that it uses WinAuthentication using my credentials. Which makes me think that unless you specify the process to be interactive, it will run under the username of the person who called AT. Its a big jump, but you might want to test it out... set a job for five minutes from now and then log out and log in as someone else and wait to see what happens. Just a thought.