Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to create a sound whenever a button is clicked? 1

Status
Not open for further replies.

WomanPro

Programmer
Nov 1, 2012
180
0
0
GR
Hello!!! I am creating a backgammon game application and I was wondering how can I add sound to button. I' m not experience to this. Can anyone guide me??? For example I have a button Roll that rolls the dices and I would like to make the sound of rolling dices. What can I do and how??? Any help will be much appreciated. Thank you very much in advanced.
 
Much depends on how you want to make the sound, but I'm sure there are .bmp files available that will emulate most sounds and you would simply play the sound while the dice are being rolled.
 
Well I need 3 sounds totally. Firstone the sound of rolling dices. Secondly the sound of tick when we play a checker and finally the winner sound. I have already created dices with picture boxes and I load to them the appropriate picture. But I can't understand what kind of code should I have to work on to create that sounds??? Must I have to download from a site some sounds and which extension??? I am not experienced to that!!! I am sorry. For example when the user clicks on the Roll Button in my form and while the dices rolling I need that sound of rolling dices. When the user clicks on backgammon board and sets a checker to a specific location I need the checker sound "tick". When the user wins the sound of the winner!!!!! Any ideas please????
 
Sounds Like Microsoft Internet Backgammon!!! I think I gave you an idea.
 
This shows you how to play a sound file

[link]http://support.microsoft.com/kb/821767[/url]

 
Oh and by the way I haven't played backgammon for over 30 years and always found it boring. I was glad when the friend who loved the game emigrated [wink]
 
Thank you so much softhemc!!!!! It helps me so muuuuuuuuuuuuuch!!!!!!!!!!! [thumbsup]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top