Lecteur mp3 avec application vb2008

ouidad02 Messages postés 46 Date d'inscription dimanche 27 décembre 2009 Statut Membre Dernière intervention 5 octobre 2011 - 12 août 2010 à 02:21
Adn56 Messages postés 1172 Date d'inscription jeudi 24 mai 2007 Statut Membre Dernière intervention 28 septembre 2013 - 12 août 2010 à 18:19
slt a tous

je cherche comment cree une application vb2008 pour la lecture mp3 "cad application qui lie les fichier mp3 par click sure un buttan"
mrc d'avant

2 réponses

NSUADI Messages postés 540 Date d'inscription mardi 4 août 2009 Statut Membre Dernière intervention 1 février 2013 2
12 août 2010 à 03:14
"Lecteur Mp3" dans la section recherche...
Ce qui compte,ce n'est pas ce qu'on a mais plutôt ce que l'on fait avec ce qu'on a...
Visual Basic .Net is the best and vb6.0
0
Adn56 Messages postés 1172 Date d'inscription jeudi 24 mai 2007 Statut Membre Dernière intervention 28 septembre 2013 1
12 août 2010 à 18:19
Le pivert à déja répondu à cette question !

Public Declare Function mciSendString Lib "winmm.dll" Alias "mciSendStringA" (ByVal lpstrCommand As String, ByVal lpstrReturnString As String, ByVal uReturnLength As Integer, ByVal hwndCallback As Integer) As Integer
    Public strFileToPlay As String
    Public bPlaying As Boolean
    Public Sub Play()
        If strFileToPlay <> "" Then
            mciSendString("play " & strFileToPlay, CStr(0), 0, 0)
            bPlaying = True
        End If
    End Sub
    Public Sub Open()
        If strFileToPlay <> "" Then
            mciSendString("open " & strFileToPlay & " type MPEGVideo", CStr(0), 0, 0)
        End If
    End Sub
    Public Sub Pause()
        If bPlaying Then
            mciSendString("pause " & strFileToPlay, CStr(0), 0, 0)
            bPlaying = False
        End If
    End Sub
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Call Pause()
        strFileToPlay = "chemin fichier.mp3"
        strFileToPlay = """" & strFileToPlay & """"
        Call Open()
        Call Play()
    End Sub
    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        'Arrete la lecture du son
        Call Pause()
    End Sub
0
Rejoignez-nous