Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Tutorial Playing mp3,mid,etc... audio files on VB 2010!
#1
Wink 
Play mp3,mid,... files on VB 2010!

First Of all We need to add a reference to the windows media player (wmp.dll).

1. Go to Project -> Add Reference (see tut1.png)
[Image: tut1ns.png]

2. A Window Should Pop Up, now go to the COM tab and scroll all th way down them just search for Windows Media player
(see tut2.png), then when you found the wmp.dll just select and press OK.
[Image: tut2b.png]

3. Now Go to the toolbox and scroll down till you reach the General Section, inside the general press the right button and selec "Choose Items..."
(see tut3.png)
[Image: tut3j.png]

4. Now go to the COM Components tab and scroll down a bit till you find the Windows Media Player, Select it and Press OK.
(see tut4.png)
[Image: tut4n.png]

5. Now just drag the Windows Media Player Object in the ToolBox(see tut5.png)
[Image: tut5c.png]
and put it anywhere in the form, select the object and go to properties and set "visible" to false.
(see tut6.png)
[Image: tut6l.png]

6. Now you need to include the music file you want into the project simply, drag the file and place it inside the project.
(see tut7.png)
[Image: tut7.png]

7. Now go to the properties from the file you just putted inside the project and change the "Copy to Output" option to "Copy Always".
(see tut8.png)
[Image: tut8v.png]

8. Then Finaly just copy this code on the disered Sub:

AxWindowsMediaPlayer1.URL = <name of the file>

Example:

AxWindowsMediaPlayer1.URL = "Promisses.mp3"

(see tut9.png)
[Image: tut9m.png]

Leave your comments...

Thanks Barata.
Reply

#2
Thumbs Up 
Great Tutorial Bro
Reply

#3
Very helpful. Thanks
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  Help mod not reading .iwd files? hmann 4 4,535 10-13-2013, 20:14
Last Post: hmann
  Help Playing sounds ingame? Some 2 3,384 09-10-2013, 10:42
Last Post: Yamato
  i need help with the sabs files duckywson 2 3,344 08-31-2013, 19:46
Last Post: duckywson
  .FF Files tugay12 1 4,367 08-14-2013, 17:11
Last Post: DidUknowiPwn
Question Help Upgrade my point system from files to Database, help? EnVi Sweden Rocks 11 9,422 08-03-2013, 23:31
Last Post: EnVi Sweden Rocks
  Help GSC Reading Files?! Howl3r 11 8,367 07-30-2013, 04:00
Last Post: DidUknowiPwn
  Help Spawn Message Playing on Respawn? Killjoy 7 5,223 07-11-2013, 14:53
Last Post: Killjoy
Music [Release] [C#] [LIBRARY] SABSFile library (open sound files) JariZ 31 19,929 07-07-2013, 17:20
Last Post: Red-EyeX32
  ranked server files for mw3 with DLC odok 5 4,626 04-19-2013, 12:09
Last Post: Nekochan
  Help audio via rank.gsc 2 CheGuevara 2 2,801 04-02-2013, 09:15
Last Post: CheGuevara

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.