首页上一页 1 下一页尾页 5 条记录 1/1页
《视频学Visual Basic》的“项目开发实战A 多媒体播放器”中的“歌词”部分的代码有误
发表在VB答疑区
2011-02-24
是否精华
是
否
版块置顶:
是
否
设置时间:
非永久
永久
起始时间:
结束时间:
是否扣分:
是
否
《视频学Visual Basic》的“项目开发实战A 多媒体播放器”中的“歌词”部分的代码有误,致使带有歌词的歌曲不能播放。麻烦作者解决!谢谢!!
精彩评论 5
2011-02-25
板凳
运行源程序"多媒体播放器.vbp"时,提示“实时错误'5':无效的过程调用或参数”,按调试按钮,显示位置如下内容中的下划线部分(红色部分):
Public Sub ShowLRC()
Dim fN As String '定义文件名
Dim iNum As Integer '存储文件扩展名的长度
If Frm_PlayList.Lvw_PlayList.ListItems.Count = 0 Then
Exit Sub
Else
fN = Frm_PlayList.List1.List(Frm_PlayList.Lvw_PlayList.selectedItem.Index - 1)
iNum = Len(GetExtension(fN))
fN = Left(fN, Len(fN) - iNum) & "lrc"
List1.Clear
Picture1.Visible = False
If LyricsAnalyse(fN) = True Then
Dim i As Integer
For i = 0 To 7
List1.AddItem " "
Next i
For i = 0 To UBound(Lyric)
List1.AddItem Space(8) & Right(Lyric(i), Len(Lyric(i)) - 10)
Next i
For i = 0 To 7
List1.AddItem " "
Next i
Else
Picture1.Visible = True
Lbl_FileName.Caption = SongName(fN)
End If
End If
End Sub
麻烦解决,谢谢!!
Public Sub ShowLRC()
Dim fN As String '定义文件名
Dim iNum As Integer '存储文件扩展名的长度
If Frm_PlayList.Lvw_PlayList.ListItems.Count = 0 Then
Exit Sub
Else
fN = Frm_PlayList.List1.List(Frm_PlayList.Lvw_PlayList.selectedItem.Index - 1)
iNum = Len(GetExtension(fN))
fN = Left(fN, Len(fN) - iNum) & "lrc"
List1.Clear
Picture1.Visible = False
If LyricsAnalyse(fN) = True Then
Dim i As Integer
For i = 0 To 7
List1.AddItem " "
Next i
For i = 0 To UBound(Lyric)
List1.AddItem Space(8) & Right(Lyric(i), Len(Lyric(i)) - 10)
Next i
For i = 0 To 7
List1.AddItem " "
Next i
Else
Picture1.Visible = True
Lbl_FileName.Caption = SongName(fN)
End If
End If
End Sub
麻烦解决,谢谢!!
2011-02-25
地板
运行源程序"多媒体播放器.vbp"时,提示“实时错误'5':无效的过程调用或参数”,按调试按钮,显示位置如下内容中的下划线部分(红色部分):
Public Sub ShowLRC()
Dim fN As String '定义文件名
Dim iNum As Integer '存储文件扩展名的长度
If Frm_PlayList.Lvw_PlayList.ListItems.Count = 0 Then
Exit Sub
Else
fN = Frm_PlayList.List1.List(Frm_PlayList.Lvw_PlayList.selectedItem.Index - 1)
iNum = Len(GetExtension(fN))
fN = Left(fN, Len(fN) - iNum) & "lrc"
List1.Clear
Picture1.Visible = False
If LyricsAnalyse(fN) = True Then
Dim i As Integer
For i = 0 To 7
List1.AddItem " "
Next i
For i = 0 To UBound(Lyric)
[font color=#FF0000]List1.AddItem Space(8) & Right(Lyric(i), Len(Lyric(i)) - 10)
[/font]Next i
For i = 0 To 7
List1.AddItem " "
Next i
Else
Picture1.Visible = True
Lbl_FileName.Caption = SongName(fN)
End If
End If
End Sub
麻烦解决,谢谢!!
Public Sub ShowLRC()
Dim fN As String '定义文件名
Dim iNum As Integer '存储文件扩展名的长度
If Frm_PlayList.Lvw_PlayList.ListItems.Count = 0 Then
Exit Sub
Else
fN = Frm_PlayList.List1.List(Frm_PlayList.Lvw_PlayList.selectedItem.Index - 1)
iNum = Len(GetExtension(fN))
fN = Left(fN, Len(fN) - iNum) & "lrc"
List1.Clear
Picture1.Visible = False
If LyricsAnalyse(fN) = True Then
Dim i As Integer
For i = 0 To 7
List1.AddItem " "
Next i
For i = 0 To UBound(Lyric)
[font color=#FF0000]List1.AddItem Space(8) & Right(Lyric(i), Len(Lyric(i)) - 10)
[/font]Next i
For i = 0 To 7
List1.AddItem " "
Next i
Else
Picture1.Visible = True
Lbl_FileName.Caption = SongName(fN)
End If
End If
End Sub
麻烦解决,谢谢!!