VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



A Mini Mp3 Player.

by Jamal 331 (5 Submissions)
Category: Miscellaneous
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Fri 31st January 2003
Date Added: Mon 8th February 2021
Rating: (1 Votes)

A Mini Mp3 Player.

Rate A Mini Mp3 Player.



'Next, you need the Gold Button control, which I do not know what site to go to.
'Then, you need 2 list boxes, 2 combo boxes, 3 gold buttons captioned play, about, exit; and a text field.
'You will also need the frmaboutmp3 form.
'Try building the MP3 player.
'Contact Me at [email protected]

(Code)

Private Sub cmdabout_Click()
frmAboutmp3.Show
End Sub

Private Sub Form_Load()
Left = (Screen.Width - Width) \ 2
Top = (Screen.Height - Height) \ 2
Combo1.Text = "*.mp3"
Combo1.AddItem "*.mp3"
Combo1.AddItem "*.mid"
Combo1.AddItem "*.wav;*.wma"

End Sub

Private Sub Combo1_Change()
If ListIndex = 0 Then
File1.Pattern = ("*.mp3")
ElseIf ListIndex = 1 Then
File1.Pattern = ("*.mid")
ElseIf ListIndex = 2 Then
File1.Pattern = ("*.wav;*.wma")
End If

End Sub


Private Sub Dir1_Change()
File1.Path = Dir1.Path
If Combo1.ListIndex = 0 Then
File1.Pattern = ("*.mp3")
ElseIf Combo1.ListIndex = 1 Then
File1.Pattern = ("*.mid")
ElseIf Combo1.ListIndex = 2 Then
File1.Pattern = ("*.wav;*.wma")
End If
End Sub

Private Sub Drive1_Change()
Dir1.Path = Drive1.Drive
End Sub

Private Sub Exit_Click()
Unload Me
End Sub

Private Sub File1_Click()
If Combo1.ListIndex = 0 Then
File1.Pattern = ("*.mp3")
ElseIf Combo1.ListIndex = 1 Then
File1.Pattern = ("*.mid")
ElseIf Combo1.ListIndex = 2 Then
File1.Pattern = ("*.wav;*.wma")
End If

If Right(File1.Path, 1) <> "\" Then
filenam = File1.Path + "\" + File1.FileName
Else
filenam = File1.Path + File1.FileName
End If
Text1.Text = filenam
End Sub
Private Sub play_Click()
MMPlayer.FileName = Text1.Text
End Sub
Private Sub stop_Click()
If MMPlayer.Mode = 524 Then Exit Sub
If MMPlayer.Mode <> 525 Then
MMPlayer.Wait = True
MMPlayer.Command = "Stop"
End If
MMPlayer.Wait = True
MMPlayer.Command = "Close"
End Sub


Download this snippet    Add to My Saved Code

A Mini Mp3 Player. Comments

No comments have been posted about A Mini Mp3 Player.. Why not be the first to post a comment about A Mini Mp3 Player..

Post your comment

Subject:
Message:
0/1000 characters