
09/12/2003, 14:30
|
 | | | Fecha de Ingreso: noviembre-2003
Mensajes: 418
Antigüedad: 21 años, 4 meses Puntos: 0 | |
una forma de hacerlo (aunque no resulta simple) es utilizar un control winsock para bajar la página y luego procesar el HTML como lo hiciste anteriormente:
primero hay que conectarse al servidor remoto.
Winsock1.RemoteHost = "microsoft.com"
Winsock1.RemotePort = 80
Winsock1.Connect
en la propiedad Connect del winsock agregar:
Dim strCommand as String
Dim strWebPage as String
strWebPage = "http://www.microsoft.com/index.shtml"
strCommand = "GET " + strWebPage + " HTTP/1.0" + vbCrLf
strCommand = strCommand + "Accept: */*" + vbCrLf
strCommand = strCommand + "Accept: text/html" + vbCrLf
strCommand = strCommand + vbCrLf
Winsock1.SendData strCommand
el control intentará descargar la página, cuando recive información hay que utilizar el evento DataArrival:
Dim webData As String
Winsock1.GetData webData, vbString
TxtWebPage.Text = TxtWebPage.Text + webData
espero te sirva de utilidad.
saludos.
__________________ La cantidad total de inteligencia del planeta permanece constante.
La población, sin embargo, sigue aumentando. COLE :cool: Los ordenadores no resuelven problemas ... ejecutan soluciones.Laurent Gasser Tienes alguna duda :pensando: ? >>> www.google.com :aplauso: <<< |