Launch Task on Resume

Hi guys,

I'm guessing it's really obvious but:
how do I set a trigger in task scheduler for when the computer resumes from hibernation?

thanks
macca
 

My Computer

System One

  • Manufacturer/Model
    Advent 9515
    CPU
    AMD Turion 64X2 2.0GHz
    Memory
    2GB
    Graphics Card(s)
    ATI Radeon X1250
    Screen Resolution
    1280x800
    Cooling
    Fan
    Internet Speed
    Should be 10Mbps, often less
I'm not 100% certain, but in the Triggers section near the top is a dropdown list. Open it and select "on connection to user session" and since that's what happens when awakening from hibernation, I suspect it will start at that point.

I hope this helps. If not, post back and I'll do more research.

Good luck!
 

My Computer

System One

  • Manufacturer/Model
    Dell Inc. MP061 Inspiron E1705
    CPU
    2.00 gigahertz Intel Core 2 Duo 64 kilobyte primary memory
    Motherboard
    Board: Dell Inc. 0YD479 Bus Clock: 166 megahertz
    Memory
    2046 Megabytes Usable Installed Memory
    Graphics Card(s)
    ATI Mobility Radeon X1400 (Microsoft Corporation - WDDM) [Di
    Sound Card
    SigmaTel High Definition Audio CODEC
    Monitor(s) Displays
    Generic PnP Monitor (17.2"vis)
    Screen Resolution
    1920 x 1200 pixels
    Hard Drives
    Hitachi HTS541616J9SA00 [Hard drive] (160.04 GB) -- drive 0, s/n SB2411SJGLLRMB, rev SB4OC74P, SMART Status: Healthy
    Case
    Chassis Serial Number: 5YK95C1
    Keyboard
    Standard PS/2 Keyboard
    Mouse
    Logitech HID-compliant Cordless Mouse
    Internet Speed
    1958 Kbps download ; 754.8 Kbps upload
    Other Info
    Optiarc DVD+-RW AD-5540A ATA Device [CD-ROM drive]

    Dell AIO Printer A940

    Conexant HDA D110 MDC V.92 Modem

    6TO4 Adapter
    Broadcom 440x 10/100 Integrated Controller
    Broadcom 802.11n Network Adapter
    Microsoft ISATAP Adapter
    Teredo Tunneling Pseudo-Interface

    Router Linksys / WRT54G -01
But wont this make it run when i boot aswell
 

My Computer

System One

  • Manufacturer/Model
    Advent 9515
    CPU
    AMD Turion 64X2 2.0GHz
    Memory
    2GB
    Graphics Card(s)
    ATI Radeon X1250
    Screen Resolution
    1280x800
    Cooling
    Fan
    Internet Speed
    Should be 10Mbps, often less
Yes That is correct

It means When ever you connect to that Log on it will Run the Command that has been set
 

My Computer

System One

  • Manufacturer/Model
    Custom Built
    CPU
    Intel Core i5 2400 @ 3.10GHz
    Motherboard
    Foxconn H67MP-S/-V/H67MP
    Memory
    8.0GB DDR3 @ 665MHz (2GBx4)
    Graphics Card(s)
    AMD HD Radeon 6870
    Sound Card
    Realtek High Definition Audio
    Monitor(s) Displays
    SMB1930NW (1440x900@60Hz)
    Screen Resolution
    1280x800
    Hard Drives
    977GB Seagate ST31000524AS ATA Device (SATA) + 250GB WD iSCSI attached Drive
    Case
    Novatech Night
    Keyboard
    Standard PS/2 Keyboard
    Mouse
    Dell HID-compliant mouse
hmm, i'm afraid that is not what I am looking for then, just something that runs on resume from hibernation
 

My Computer

System One

  • Manufacturer/Model
    Advent 9515
    CPU
    AMD Turion 64X2 2.0GHz
    Memory
    2GB
    Graphics Card(s)
    ATI Radeon X1250
    Screen Resolution
    1280x800
    Cooling
    Fan
    Internet Speed
    Should be 10Mbps, often less
Yes, and possibly on restarts and logoff/logons and possibly even resumes from locked systems or even password-protected screensavers. I didn't realize you meant ONLY for hibernation. Does that mean you don't want it to occur on awakening from sleep mode either? That's going to be harder (I'll definitely need to research that one and get back to you as I've never done it or tried it before). Just out of curiosity, what task would you want to occur when awakening from hibernation that you would not want to occur with a normal startup or from sleep?

Thanks and I'll look into it now that I better understand.
 

My Computer

System One

  • Manufacturer/Model
    Dell Inc. MP061 Inspiron E1705
    CPU
    2.00 gigahertz Intel Core 2 Duo 64 kilobyte primary memory
    Motherboard
    Board: Dell Inc. 0YD479 Bus Clock: 166 megahertz
    Memory
    2046 Megabytes Usable Installed Memory
    Graphics Card(s)
    ATI Mobility Radeon X1400 (Microsoft Corporation - WDDM) [Di
    Sound Card
    SigmaTel High Definition Audio CODEC
    Monitor(s) Displays
    Generic PnP Monitor (17.2"vis)
    Screen Resolution
    1920 x 1200 pixels
    Hard Drives
    Hitachi HTS541616J9SA00 [Hard drive] (160.04 GB) -- drive 0, s/n SB2411SJGLLRMB, rev SB4OC74P, SMART Status: Healthy
    Case
    Chassis Serial Number: 5YK95C1
    Keyboard
    Standard PS/2 Keyboard
    Mouse
    Logitech HID-compliant Cordless Mouse
    Internet Speed
    1958 Kbps download ; 754.8 Kbps upload
    Other Info
    Optiarc DVD+-RW AD-5540A ATA Device [CD-ROM drive]

    Dell AIO Printer A940

    Conexant HDA D110 MDC V.92 Modem

    6TO4 Adapter
    Broadcom 440x 10/100 Integrated Controller
    Broadcom 802.11n Network Adapter
    Microsoft ISATAP Adapter
    Teredo Tunneling Pseudo-Interface

    Router Linksys / WRT54G -01
You may want to do it for "On Workstation Unlock"

This means that the Task will run when the User Unlocks there Workstation this means it will not run when Starting up and logging in but will Run when you boot from Hibernate and Unlock that User

Hope This Helps,
Josh
 

My Computer

System One

  • Manufacturer/Model
    Custom Built
    CPU
    Intel Core i5 2400 @ 3.10GHz
    Motherboard
    Foxconn H67MP-S/-V/H67MP
    Memory
    8.0GB DDR3 @ 665MHz (2GBx4)
    Graphics Card(s)
    AMD HD Radeon 6870
    Sound Card
    Realtek High Definition Audio
    Monitor(s) Displays
    SMB1930NW (1440x900@60Hz)
    Screen Resolution
    1280x800
    Hard Drives
    977GB Seagate ST31000524AS ATA Device (SATA) + 250GB WD iSCSI attached Drive
    Case
    Novatech Night
    Keyboard
    Standard PS/2 Keyboard
    Mouse
    Dell HID-compliant mouse
Yes, and possibly on restarts and logoff/logons and possibly even resumes from locked systems or even password-protected screensavers. I didn't realize you meant ONLY for hibernation. Does that mean you don't want it to occur on awakening from sleep mode either? That's going to be harder (I'll definitely need to research that one and get back to you as I've never done it or tried it before). Just out of curiosity, what task would you want to occur when awakening from hibernation that you would not want to occur with a normal startup or from sleep?

Thanks and I'll look into it now that I better understand.

I dont mind if it comes on after sleep, just not on startup
 

My Computer

System One

  • Manufacturer/Model
    Advent 9515
    CPU
    AMD Turion 64X2 2.0GHz
    Memory
    2GB
    Graphics Card(s)
    ATI Radeon X1250
    Screen Resolution
    1280x800
    Cooling
    Fan
    Internet Speed
    Should be 10Mbps, often less
As a developer, I can foresee several problems. Can you please give us a bit of a clue as to what you are trying to achieve. It is very different to start an .exe, compared to a .vbs script, with a Word Document.

Also, how long is this task going to take, and does it have a UI. You don't want to cause the Windows Kernal to hang, waiting for the task to complete.

Also, there may be focus issues. It will be started before a lot of other things, and so will be displayed at the back of the Desktop. Does this matter?

Does it require UAC elevation?

All of these have workaround. Issues with focus for example can be solved, but not while we know nothing about the question!

Thanks!

Richard
 

My Computer

System One

  • Manufacturer/Model
    Dell XPS 420
    CPU
    Intel Core 2 Quad Q9300 2.50GHz
    Motherboard
    Stock Dell 0TP406
    Memory
    4 gb (DDR2 800) 400MHz
    Graphics Card(s)
    ATI Radeon HD 3870 (512 MBytes)
    Sound Card
    Onboard
    Monitor(s) Displays
    1 x Dell 2007FP and 1 x (old) Sonic flat screen
    Screen Resolution
    1600 x 1200 and 1280 x 1204
    Hard Drives
    1 x 640Gb (SATA 300)
    Western Digital: WDC WD6400AAKS-75A7B0

    1 x 1Tb (SATA 600)
    Western Digital: Caviar Black, SATA 6GB/S, 64Mb cache, 8ms
    Western Digital: WDC WD1002FAEX-00Z3A0 ATA Device
    PSU
    Stock PSU - 375W
    Case
    Dell XPS 420
    Cooling
    Stock Fan
    Keyboard
    Dell Bluetooth
    Mouse
    Advent Optical ADE-WG01 (colour change light up)
    Internet Speed
    120 kb/s
    Other Info
    ASUS USB 3.0 5Gbps/SATA 6Gbps - PCI-Express Combo Controller Card (U3S6)
You may want to do it for "On Workstation Unlock"

This means that the Task will run when the User Unlocks there Workstation this means it will not run when Starting up and logging in but will Run when you boot from Hibernate and Unlock that User

Hope This Helps,
Josh

While this will run it on awakening from hibernation and sleep (and sleep seems to be OK here), and I agree it will not run at startup or if he changes users even without a reboot (though I'm not 100% certain on that one - but believe it to be the case and would want to test it), I believe this option will also cause it to run if he locks his PC (say he goes to the bathroom and doesn't need hibernation) and then unlocks it and possibly even if he password-protects the screensaver and unlocks the system from that as well.

I don't think any of the standard options will work if he ONLY wants it to run when awakening from hibernation (or sleep) and at no other time (specifically not at startup, but I think he means any other situation as well).

================================================

@ maccaquacker, please correct me if I'm assuming incorrectly as I'm now taking a very narrow view of your request. It would help to know if we have any additional leeway besides just sleep mode. Also, and this is important, we need answers to Richard's questions since the methodology (if possible) is likely to be much more complicated than any ordinary task (or even those typically considered complex but included in the standard configuration options). Knowing what needs to be done is crucial to finding the best way to do it (or seeing if it can be done at all and if so, then identifying and dealing with the potential consequences). Please describe in as much detail as possible EXACTLY what this task is supposed to do, what files or programs it involves, how long the task would take if done manually, and anything else you think might help us understand.

Thanks for your help and guidance and whatever you can provide.

Good luck!
 
Last edited:

My Computer

System One

  • Manufacturer/Model
    Dell Inc. MP061 Inspiron E1705
    CPU
    2.00 gigahertz Intel Core 2 Duo 64 kilobyte primary memory
    Motherboard
    Board: Dell Inc. 0YD479 Bus Clock: 166 megahertz
    Memory
    2046 Megabytes Usable Installed Memory
    Graphics Card(s)
    ATI Mobility Radeon X1400 (Microsoft Corporation - WDDM) [Di
    Sound Card
    SigmaTel High Definition Audio CODEC
    Monitor(s) Displays
    Generic PnP Monitor (17.2"vis)
    Screen Resolution
    1920 x 1200 pixels
    Hard Drives
    Hitachi HTS541616J9SA00 [Hard drive] (160.04 GB) -- drive 0, s/n SB2411SJGLLRMB, rev SB4OC74P, SMART Status: Healthy
    Case
    Chassis Serial Number: 5YK95C1
    Keyboard
    Standard PS/2 Keyboard
    Mouse
    Logitech HID-compliant Cordless Mouse
    Internet Speed
    1958 Kbps download ; 754.8 Kbps upload
    Other Info
    Optiarc DVD+-RW AD-5540A ATA Device [CD-ROM drive]

    Dell AIO Printer A940

    Conexant HDA D110 MDC V.92 Modem

    6TO4 Adapter
    Broadcom 440x 10/100 Integrated Controller
    Broadcom 802.11n Network Adapter
    Microsoft ISATAP Adapter
    Teredo Tunneling Pseudo-Interface

    Router Linksys / WRT54G -01
You may want to do it for "On Workstation Unlock"

This means that the Task will run when the User Unlocks there Workstation this means it will not run when Starting up and logging in but will Run when you boot from Hibernate and Unlock that User

Hope This Helps,
Josh

While this will run it on awakening from hibernation and sleep (and sleep seems to be OK here), and I agree it will not run at startup or if he changes users even without a reboot (though I'm not 100% certain on that one - but believe it to be the case and would want to test it), I believe this option will also cause it to run if he locks his PC (say he goes to the bathroom and doesn't need hibernation) and then unlocks it and possibly even if he password-protects the screensaver and unlocks the system from that as well.

I don't think any of the standard options will work if he ONLY wants it to run when awakening from hibernation (or sleep) and at no other time (specifically not at startup, but I think he means any other situation as well).


I agree completly this is a Sort of "Work around" Solution
 

My Computer

System One

  • Manufacturer/Model
    Custom Built
    CPU
    Intel Core i5 2400 @ 3.10GHz
    Motherboard
    Foxconn H67MP-S/-V/H67MP
    Memory
    8.0GB DDR3 @ 665MHz (2GBx4)
    Graphics Card(s)
    AMD HD Radeon 6870
    Sound Card
    Realtek High Definition Audio
    Monitor(s) Displays
    SMB1930NW (1440x900@60Hz)
    Screen Resolution
    1280x800
    Hard Drives
    977GB Seagate ST31000524AS ATA Device (SATA) + 250GB WD iSCSI attached Drive
    Case
    Novatech Night
    Keyboard
    Standard PS/2 Keyboard
    Mouse
    Dell HID-compliant mouse
As a developer, I can foresee several problems. Can you please give us a bit of a clue as to what you are trying to achieve. It is very different to start an .exe, compared to a .vbs script, with a Word Document.


Thanks!

Richard

I just need to see the UI of taskmgr.exe within the first sort-of minute or so since boot. Mainly so I can see the stats in the performance tab and also the uptime stats etc.

Its mainly about the uptime as I am bothered about how long my PC has been running from a cold start but resuming from hibernate does not reset that information so I want to see how long the computer was on previously so I can figure out how long the current session has been active for
 

My Computer

System One

  • Manufacturer/Model
    Advent 9515
    CPU
    AMD Turion 64X2 2.0GHz
    Memory
    2GB
    Graphics Card(s)
    ATI Radeon X1250
    Screen Resolution
    1280x800
    Cooling
    Fan
    Internet Speed
    Should be 10Mbps, often less
It is not essential if it does not run instantly/ on resume from sleep, just ideally not at boot althought I am happy for this to be the case if needs be
 

My Computer

System One

  • Manufacturer/Model
    Advent 9515
    CPU
    AMD Turion 64X2 2.0GHz
    Memory
    2GB
    Graphics Card(s)
    ATI Radeon X1250
    Screen Resolution
    1280x800
    Cooling
    Fan
    Internet Speed
    Should be 10Mbps, often less
The choice is yours but The closest you are going to get to your Needs is When you unlock your Computer, This will not run on boot

Josh
 

My Computer

System One

  • Manufacturer/Model
    Custom Built
    CPU
    Intel Core i5 2400 @ 3.10GHz
    Motherboard
    Foxconn H67MP-S/-V/H67MP
    Memory
    8.0GB DDR3 @ 665MHz (2GBx4)
    Graphics Card(s)
    AMD HD Radeon 6870
    Sound Card
    Realtek High Definition Audio
    Monitor(s) Displays
    SMB1930NW (1440x900@60Hz)
    Screen Resolution
    1280x800
    Hard Drives
    977GB Seagate ST31000524AS ATA Device (SATA) + 250GB WD iSCSI attached Drive
    Case
    Novatech Night
    Keyboard
    Standard PS/2 Keyboard
    Mouse
    Dell HID-compliant mouse
Ok then, thanks for now

Macca
 

My Computer

System One

  • Manufacturer/Model
    Advent 9515
    CPU
    AMD Turion 64X2 2.0GHz
    Memory
    2GB
    Graphics Card(s)
    ATI Radeon X1250
    Screen Resolution
    1280x800
    Cooling
    Fan
    Internet Speed
    Should be 10Mbps, often less
No, there is a way. I was just about to figure it out, when I discovered that my Event Log service has broken. More work! You need to find an Event in the Event Log that only fires on resume from Hibernation. Then something similar to:

Task Scheduler > Create Task > Triggers Tab > New Trigger > On an Event dropdown > Log: Microsoft-Windows-Winlogon/Operational I would imagine.

Sorry I cannot be of more help at the present.
 

My Computer

System One

  • Manufacturer/Model
    Dell XPS 420
    CPU
    Intel Core 2 Quad Q9300 2.50GHz
    Motherboard
    Stock Dell 0TP406
    Memory
    4 gb (DDR2 800) 400MHz
    Graphics Card(s)
    ATI Radeon HD 3870 (512 MBytes)
    Sound Card
    Onboard
    Monitor(s) Displays
    1 x Dell 2007FP and 1 x (old) Sonic flat screen
    Screen Resolution
    1600 x 1200 and 1280 x 1204
    Hard Drives
    1 x 640Gb (SATA 300)
    Western Digital: WDC WD6400AAKS-75A7B0

    1 x 1Tb (SATA 600)
    Western Digital: Caviar Black, SATA 6GB/S, 64Mb cache, 8ms
    Western Digital: WDC WD1002FAEX-00Z3A0 ATA Device
    PSU
    Stock PSU - 375W
    Case
    Dell XPS 420
    Cooling
    Stock Fan
    Keyboard
    Dell Bluetooth
    Mouse
    Advent Optical ADE-WG01 (colour change light up)
    Internet Speed
    120 kb/s
    Other Info
    ASUS USB 3.0 5Gbps/SATA 6Gbps - PCI-Express Combo Controller Card (U3S6)
Back
Top