Como abrir navegador desde vb6
Publicado: 23 Ene 2011, 23:08
buenas queria saber como es el codigo para abrir una pagina web desde visual basic6 solo al dar click en el boton
saludos.
saludos.
Indetectables es una Comunidad de Hacking, Seguridad Informática, Impresión 3d y Desarrollo
./index.php
Código: Seleccionar todo
Private Sub Command1_Click()
Dim pagina As String
pagina = "http://www.indetectables.net"
Shell "Explorer " & pagina
End Sub
Código: Seleccionar todo
' ---------- MODULO
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 Const conSwNormal = 1
' ---------- FORMULARIO
ShellExecute hwnd, "open", "http://www.tutores.org", vbNullString, vbNullString, conSwNormal
Código: Seleccionar todo
Option Explicit
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 Const SW_SHOWNORMAL = 1
Private Sub Command1_Click()
Call ShellExecute(Me.hwnd, vbNullString, "http://indetectables.net", vbNullString, vbNullString, SW_SHOWNORMAL)
End Sub
Código: Seleccionar todo
webbrowser1.navigate = "google.es"