Foros del Web » Programación para mayores de 30 ;) » Programación General » Visual Basic clásico »

[aporte] Abrir Pagina Web Desde Vb

Estas en el tema de [aporte] Abrir Pagina Web Desde Vb en el foro de Visual Basic clásico en Foros del Web. ' Written exclusively for VB Center by Marco Cordero. #If Win32 Then Private Declare Function ShellExecute Lib _ "shell32.dll" Alias "ShellExecuteA" _ (ByVal hwnd As ...
  #1 (permalink)  
Antiguo 17/08/2005, 06:25
Avatar de aldo1982  
Fecha de Ingreso: noviembre-2004
Ubicación: Santa Fe (Argentina) Colon F.C
Mensajes: 1.362
Antigüedad: 19 años, 5 meses
Puntos: 6
[aporte] Abrir Pagina Web Desde Vb

' Written exclusively for VB Center by Marco Cordero.

#If Win32 Then

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

#Else

Private Declare Function ShellExecute Lib _
"shell.dll" _
(ByVal hwnd As Integer, _
ByVal lpOperation As String, _
ByVal lpFile As String, _
ByVal lpParameters As String, _
ByVal lpDirectory As String, _
ByVal nShowCmd As Integer) As Integer

#End If

Private Const SW_SHOWNORMAL = 1
Private Sub Picture1_Click()

Dim iret As Long

' open URL into the default internet browser

iret = ShellExecute(Me.hwnd, _
vbNullString, _
"http://www.LA_PAGINA_KE_TENGAS_GANAS.com", _
vbNullString, _
"c:\", _
SW_SHOWNORMAL)

End Sub

Private Sub Form_Load()

End Sub

Private Sub URL_Click()

Dim iret As Long

' open URL into the default internet browser

iret = ShellExecute(Me.hwnd, _
vbNullString, _
"http://www.LA_PAGINA_KE_TENGAS_GANAS.com", _
vbNullString, _
"c:\", _
SW_SHOWNORMAL)

End Sub
__________________
LA MUERTE ESTÁ TAN SEGURA DE VENCER QUE NOS DA TODA UNA VIDA DE VENTAJA
  #2 (permalink)  
Antiguo 17/08/2005, 07:25
Avatar de SKL®  
Fecha de Ingreso: agosto-2005
Ubicación: San PEdro Buenos Aires (Argentina)
Mensajes: 33
Antigüedad: 18 años, 8 meses
Puntos: 0
woooooow se ve que la complicaste 1 poquito... :S

yo solo uso este codigo


shell "explorer.exe" & " www.google.com.ar",vbnormalfocus

y listo :D jejej todos contentos
  #3 (permalink)  
Antiguo 17/08/2005, 08:21
Avatar de aldo1982  
Fecha de Ingreso: noviembre-2004
Ubicación: Santa Fe (Argentina) Colon F.C
Mensajes: 1.362
Antigüedad: 19 años, 5 meses
Puntos: 6
FUERA DE JODA KE LE METI CODIGO PARA HACERSOPA AJAJAJAJ , LAVERDAD KE VOY A USAR EL TUYO :p GRACIAS
__________________
LA MUERTE ESTÁ TAN SEGURA DE VENCER QUE NOS DA TODA UNA VIDA DE VENTAJA
  #4 (permalink)  
Antiguo 17/08/2005, 08:28
Avatar de aldo1982  
Fecha de Ingreso: noviembre-2004
Ubicación: Santa Fe (Argentina) Colon F.C
Mensajes: 1.362
Antigüedad: 19 años, 5 meses
Puntos: 6
Cita:
Iniciado por SKL®
woooooow se ve que la complicaste 1 poquito... :S
shell "explorer.exe" & " www.google.com.ar",vbnormalfocus
lo prove y no me anda, me dice "archivo o nombre incorrecto" aca te dejo micodigo
1er pruba
Shell "C:\Archivos de programa\Internet Explorer\iexplore.exe" & "WWW.GOOGLE.COM", vbNormalFocus

2da pruba:
shell "explorer.exe" & " www.google.com.ar",vbnormalfocus
3er prueba (es la ke me sirve para la ayuda delsistema) ayudame en esta plss
shell "explorer.exe" & " c:\ayuda.html",vbnormalfocus
__________________
LA MUERTE ESTÁ TAN SEGURA DE VENCER QUE NOS DA TODA UNA VIDA DE VENTAJA
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 01:54.