Ok i want to add background music to my app whst the easiest way to do that ? like the smallest code iv tried loads of thing but they didnt work then locohacker.net told me to come here so i came here so if anyone knows how please post thanks :)
Printable View
Ok i want to add background music to my app whst the easiest way to do that ? like the smallest code iv tried loads of thing but they didnt work then locohacker.net told me to come here so i came here so if anyone knows how please post thanks :)
You could create a media player object and then load a song into that.
It depends on the type of music you are wanting. If its a wav file, you can simply do it with:
That way you don't have the extra overhead of the media player control running in memory.VB Code:
My.Computer.Audio.Play("c:\somesong.wav")
If you are wanting to play MP3's or multiple sounds, then check out my signature for "Sounds With Managed DirectX", which shows how you can do that.
ok thank you man :) appricate it im just workin on some project and its giving me trouble