Controlling Sound in GUI

2 views (last 30 days)
Darryl
Darryl on 17 Apr 2015
Commented: Geoff Hayes on 19 Apr 2015
I've created a program, and I want the user to have music while it's running. I tried to use the 'audioplayer' function, but I couldn't get the music to play. To get around this, I added in the Window Media Player activex. I've figure out how to get it to start or stop playing with a toggle button, but I wan't to assign the volume to a slider. I can't figure out how to do this. I would also like to assign the mute feature to a check box. How do I do this?
  1 Comment
Geoff Hayes
Geoff Hayes on 19 Apr 2015
Darryl - see one of the "answers" at http://www.mathworks.com/matlabcentral/answers/94399-how-can-i-play-a-windows-media-file-using-the-appropriate-activex-control-in-my-gui-in-matlab which asks the question on how to control the volume. Perhaps you can access the volume with the handles.activex1.settings.volume (or something similar).
By the way, what problems did you have with the audioplayer?

Sign in to comment.

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!