Running a script when a sound from an application is played - windows

I would like to trigger a script on my computer (Windows 7 Professional SP1 64bit) when a particular event occurs (event 'X'). There is already an application on my computer which plays a 1 second chime (.wav sound file) whenever event X occurs. Therefore, I would like to trigger my script whenever this sound file is being played.
How can I trigger a script to run when a particular sound file is played?

Related

windows 10 microphone monitoring

I am trying to build an application for windows 10 to inform me when a process starts using my microfone. I tried to inspect opened files (handlers) with ProcessExplorer but it doesn't give me any specific information about which handler corresponds to my default sound input. What I am trying to do is almost what windows 10 already does when it puts a mic icon on system tray whenever a process open my microfone. I am hoping someone who have some knowledge on how windows sub systems works could shed some light into this. Thanks.

powershell script to play a music folder on windows startup

How to use powershell to autoplay a folder of mp3 files using Windows Media Player on Windows 7 startup. I figure that there are two aspects: 1) the script must run automatically when Windows starts up 2) the script must call Media Player to open the folder and play the files therein
Perhaps you could make a playlist from that folder in Windows Media Player.
Then you could call windows media player with a commandline switch, which tells it to open and play a certain playlist. You can find some information on commandline switches for WMP here:
[http://www.tech-recipes.com/rx/1389/windows-media-player-wmp-11-command-line-options/]
When that is done, you would create a scheduled job, to fire your WMP script every time you log on.
Information for that part can be found here:
[https://technet.microsoft.com/en-us/library/cc748993(v=ws.11).aspx]

How to configure an autoplay of music when plug in earbuds in a pc/laptop?

Just like on android I would like to be able to auto launch my music player, in this case playing music already, every time I plug the earbuds.
I know I can create a shortcut for it using the command line structure for example to open my default music folder:
vlc.exe "[path to folder]"
in this case something like this:
"C:\Program Files (x86)\VideoLAN\VLC\vlc.exe" "G:\Musics"
just like this:
What is missing to me is a way to detect the event of plugging the earbud connector. I know it is possible since the bundle software of my sound card installed an background application that alerts with a baloon message in the notification bar when the phones are plugged in.
I know That it will require some kind of service/application running in the background all the time. Does anyone have an idea of how to do it?

Looping windows programs in script

Scripting windows 7 I need to loop continously from a windows media player play list and when tje playlist is complete to a presentation and then back to the Playlist when the presentation is complete.

WP7 how to start audio agent process

I'm using BackgroundAudioPlayer agent for my Windows Phone 7 application. I know that the AudioPlayer class lives in another process (let's call it audio agent process).
I heard that "In theory the process for an Audio Player agent could get started and stopped at any time".
Sometimes, when I press play on my UI, the agent process seems to NOT start, and the agent code doesnot receive any OnUserAction event. And this cause my application to behave wrongly.
I want the agent process to be ready when I want to play music. How to fix this ?
Maybe you need to start playing audio inside dispatcher? Something like next:
Dispatcher.BeginInvoke( () => { StartAudioOrSoOn(); });
Try to check examples provided by Microsoft for Windows Phone developers:
Windows Phone Samples: learn through code

Resources