1,451
社区成员
发帖
与我相关
我的任务
分享
Private Sub Combo1_Click()
If Combo1.Text = "老虎" Then
Set Me.Picture = LoadPicture("c:\laohu.jpg")
ElseIf Combo1.Text = "狮子" Then
Set Me.Picture = LoadPicture("c:\shizi.jpg")
End If
End Sub
Set Me.Picture = LoadResPicture(laohu,VBResbitmap)
Private Sub Combo1_Click()
Dim strAppPath As String '应用程序目录
strAppPath = App.Path
If Right(strAppPath, 1) <> "\" Then strAppPath = strAppPath & "\"
If Combo1.Text = "老虎" Then
Set Me.Picture = LoadPicture(strAppPath & "laohu.jpg")
ElseIf Combo1.Text = "狮子" Then
Set Me.Picture = LoadPicture(strAppPath & "shizi.jpg")
End If
End Sub