I want to schedule a windows task to run when a secondary output device (e.g., VGA monitor or HDMI A/V receiver is turned on or off) but I'm not sure which event should be used for this. I found something related to network cable plug/unplug here How to launch a command on network connection/disconnection? , but nothing for external audio/video devices. Any such event or events exist? If not, any other way to do this? Thanks
Asked
Active
Viewed 2,117 times
1 Answers
1
Following on from your link above, I found that I could get this working for audio devices using the following event data:
Log: Microsoft-Windows-DeviceSetupManager/Admin
Source: DeviceSetupManager
Event ID: 112
ID 112 seems to process newly connected devices. In Windows logs I had the following:
Device 'LG-BDHT' ({db41aaf1-ce7e-5de5-904e-9b6d7560d7ba}) has been serviced, processed 4 tasks, wrote 0 properties, active worktime was 427 milliseconds.
This event seems to occur when I turn on my Bluray player (which then allows pass through access to my TV as a monitor).
Hope this could help you get things working! Worst case scenario, look through you event logs for something that happens around the time that your TV turns on.
wonea
- 1,877
dansimpson
- 11