
Sonido
Publicado por Analia (28 intervenciones) el 05/01/2007 12:13:02
Hola !!, quiero reproducir sonido en mi aplicacion prove con el siguiente codigo pero me da error de compilacion :
Private Sub browse_Click()
CommonDialog1.ShowOpen
List1.ListBox = CommonDialog1.Filename
End Sub
On Error Resume Next
If List1.ListBox = "" Then
MsgBox "Please Browse or Enter a File in the Text Box", vbOKOnly + vbCritical, "Geez..."
Else
sndPlaySound List1.ListBox, 0
i = mciSendString("open " & List1.ListBox & " type sequencer alias myfile", 0&, 0, 0)
i = mciSendString("play myfile wait", 0&, 0, 0)
i = mciSendString("close myfile", 0&, 0, 0)
End If
Quiero hacer una pequeña lista de reproduccion, alguien podria decirme donde esta el error.
Private Sub browse_Click()
CommonDialog1.ShowOpen
List1.ListBox = CommonDialog1.Filename
End Sub
On Error Resume Next
If List1.ListBox = "" Then
MsgBox "Please Browse or Enter a File in the Text Box", vbOKOnly + vbCritical, "Geez..."
Else
sndPlaySound List1.ListBox, 0
i = mciSendString("open " & List1.ListBox & " type sequencer alias myfile", 0&, 0, 0)
i = mciSendString("play myfile wait", 0&, 0, 0)
i = mciSendString("close myfile", 0&, 0, 0)
End If
Quiero hacer una pequeña lista de reproduccion, alguien podria decirme donde esta el error.
Valora esta pregunta


0