Membuat Link Dari Visual Basic 6.0 menuju Website

Source code berikut untuk membuat Link pada CommandButton Visual Basic 6.0.

Pada menu "New Project" pilih "Standard EXE"
Buat 1 Project dengan :
1 Command Button
1 Modul

Copy code dibawah ini dan Paste code tersebut di dalam CommandButton

Private Sub Command1_Click()
OpenURL "http://Blog17Lamers.blogspot.com", Me.hWnd
End Sub

Copy code dibwah ini dan Paste code tersebut didalam Modul

Public 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
Public Sub OpenURL(situs As String, sourceHWND As Long)
Call ShellExecute(sourceHWND, vbNullString, situs, vbNullString, vbNullString, 1)
End Sub 

 http://Blog17Lamers.blogspot.com Bisa diganti dengan Alamat Website yang anda mau ...
Suka Dengan Artikel Ini ?

 
 
Copyright © 2013. BLOGGER Mr.17 - All Rights Reserved