Jump to content
Macro Express Forums

Scheduled Hibernation Issue...


Recommended Posts

Problems scheduling hibernation under Microsoft Windows XP SP2.

(similar to http://pgmacros.com/community/index.php?showtopic=2018)


I've setup a script that uses AT.Exe & PSShutDown.Exe (both Microsoft/SysInternals) to setup a Task Scheduler JOB intended to hibernate the computer at a specific time. (this is actually a SLEEP TIMER script for WinTV)


The problem is, like all services, Scheduler runs under SYSTEM access rights and therefore any command it launches will also not have the hibernation privledge.


So in place of PSShutDown I created an exported MXE file named "Hibernate", of course containing MacEx's Hibernate command; then pointed the Scheduler service to launch at a specific time.


I assumed that MacEx already running under USER rights would read the file and initiate hibernation. Instead, a seperate copy of MacEx is launched by association to read the file and execute the command... of course resulting in privledge declination. <_<


Do you know of any way to accomplish this ?






Even though when MacEx is launched under SYSTEM access interactively, it still cannot seem to interact with desktop applications such as explorer... which can of course, initiate hibernation. I have even tried running the Scheduler service under USER rights only to find that causes other problems.


The only other option I can think of, is to setup the script to create a scheduled macro to be executed at a specified time. But there doesn't appear to be a way to accomplish this.


From what this person is saying, http://pgmacros.com/community/index.php?showtopic=2018 another unexplored alternative might be to point the scheduler service toward launching a VBS (visual basic script) file which will in-turn call upon PSShutdown or the custom MXE file ???


Been racking my brain over this and will *not* place my password on a commandline with PSExec... the only other unexplored work-around.


Input appreciated.

Link to comment
Share on other sites

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...