Is there some way, hopefully in .Net, although I could mangle something together in开发者_开发百科 C if necessary, to listen for an event when something is plugged into the headphone jack in Windows 7? To put this into perspective, When I plug in my headphones, Windows is aware, and shows me a little bubble alerting me that there was something plugged into the audio jack. I was looking to write a program that would monitor if headphones were plugged in, and if so, unmute the audio. When the headphones are removed, the auto should again be muted. Is it possible to listen for events on the audio jack?
You can use endpoint device events.
精彩评论