Hyperlink auf Label

CallWebSite, ShellExecute
Private Declare Function ShellExecute Lib "Shell32.dll" Alias _
 ShellExecuteA (ByVal hwnd As Long, ByVal lpOperation As String, _
 ByVal lpFile As String, ByVal lpParameters As String, _
 ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long
Private Function CallWebSite(ByVal URL As String) As Long
 CallWebSite = ShellExecute(0&, vbNullString, URL, _
 vbNullString, vbNullString, vbMaximizedFocus)
End Function
Private Sub lbl_1_Click()
 CallWebSite (lbl_1.Caption)
End Sub
Private Sub lbl_2_Click()
 CallWebSite (lbl_2.Caption)
End Sub
Private Sub Form_Load()
With lbl_1
 .ForeColor = &HFF0000
 .Font.Underline = True
 .MousePointer = 99
 .Caption = "http://www.bmw.de"
 .MouseIcon = LoadPicture("hand.cur") Vorher in der IDE laden
End With
With lbl_2
 .ForeColor = &HFF0000
 .Font.Underline = True
 .MousePointer = 99
 .Caption = "mailto:georgius@gmx.net"
 .MouseIcon = LoadPicture("hand.cur") Vorher in der IDE laden
End With
End Sub



 Ranking-Hits zurück Sitemap
Designed by www.wbrnet.info