• Welcome to ForumKorner!
    Join today and become a part of the community.

Visual Basic Backround Music

AussieBacom

Member
Reputation
0
Just for newbies like me to coding i found a good sting to use after the form1 or your main form in the coding section.

This was done in VS 2010 U.
Ill inclice the form1 load form for easy finding if you dont put yours at the start:
Heres the code for a song called WAVESONG.wav:
Code:
 Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
      My.Computer.Audio.Play(My.Resources.WAVESONG, AudioPlayMode.Background)
    End Sub

Heres the loop version: "Just adding a loop the the backround"
Code:
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
      My.Computer.Audio.Play(My.Resources.WAVESONG, AudioPlayMode.BackgroundLoop)
    End Sub

Hope this hepls!
icon10.gif
 
Reputation
0
Thanks, but is there a time when this isn't just annoying? So long as the skids don't get a hold of this it'll be okay though, singing viruses? That'd be chaos :p

But seriously, thanks for the tut.
 
Top