📎 AI Summary:
The thread discusses how to add volume control sliders and toggle options for background music and sound effects in a C# Windows Forms application using Visual Studio 2015. The original poster seeks guidance on implementing these features, while a responder clarifies that checks for checkbox states can control playback, and provides tips on identifying the framework within project properties. Overall, the exchange is technical, focusing on integrating basic audio controls into the application.

douglasw782

New Member
Joined
Jun 7, 2016
Messages
2
Thread Author #1
I have an issue that I hope someone can shed some light on, for me. I am creating a windows form application that I want to have backround music and sound effects incorporated into the program. I have the background music in my program, already, but, I want to add two sliders. I need the first slider to be able to turn the music volume up and down and have a checkbox toggle the music on and Off. I need the second to have the same function for the sound effects. I also need these to be operated by the program's user. If anyone could give me instructions on how to achieve this, it would be greatly appreciated.


Sent from my iPad using Tapatalk
 

Solution
It will be under Project > <Projectname> Properties

So if you are using SoundPlayer you would just need to check to see if your checkbox is checked or not, if it's muted then you don't do anything and if it not muted you play your sound. Same thing for music, but you will want a MusicMuted_CheckBox that handles the music checkbox checked_change event and then start or stop the music accordingly.

Neemobeer

Windows Forum Team
Staff member
Joined
Jul 4, 2015
Messages
8,995
It would help to know what language you are using and if it's a .Net language which framework. Also what are you using to play music?
 

douglasw782

New Member
Joined
Jun 7, 2016
Messages
2
Thread Author #3
I'm using C#. To play the music, I used sound player. As for a framework, could you possibly tell me how to find that information? I'm using Visual Studio 2015, and I'm rather new to the program.


Sent from my iPad using Tapatalk
 

Neemobeer

Windows Forum Team
Staff member
Joined
Jul 4, 2015
Messages
8,995
It will be under Project > <Projectname> Properties

So if you are using SoundPlayer you would just need to check to see if your checkbox is checked or not, if it's muted then you don't do anything and if it not muted you play your sound. Same thing for music, but you will want a MusicMuted_CheckBox that handles the music checkbox checked_change event and then start or stop the music accordingly.
 

Solution