0

I have an EXE file that I need to run immediately before I hibernate my Windows 8 PC, every time. How can I do this? I know I can use the Task Scheduler to accomplish this, but which trigger is best suited for this?

Some information about my Windows 8 PC environment: I have a password on my user account, but I have the "automatically login" option enabled, so I never have to enter it when turning on or waking my PC.

I'd like for this script to run when hibernating my PC, but if the trigger also runs when the PC sleeps, then that's fine, too. But the hibernation part is the important part, because I almost always hibernate my PC every night. I think the PC only goes to sleep if I leave it on but it idles for about an hour.

1

1 Answer 1

0

By default a Windows 7 or 8 PC will do hybrid sleep - this saves the state to disk like hibernate but then goes to sleep instead of shutting off. Then if power is lost it can resume as if the system was hibernated but otherwise it will just wake from sleep which is much faster.

An ID=42 event will appear in the system log from the KERNEL-POWER source when the system is entering sleep (either sleep or hybrid sleep).

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .