can someone show me a simple way of doing this?
winsock.remotehost = "http://www.mysite.com"
port = 80
and then a GET for blah.txt
and it should download this and save it in C:\stuff
any help guys please?
Printable View
can someone show me a simple way of doing this?
winsock.remotehost = "http://www.mysite.com"
port = 80
and then a GET for blah.txt
and it should download this and save it in C:\stuff
any help guys please?
Why do you want to go through all the trouble of making a connection with Winsock? You could simply use this API call:
VB Code:
Private Declare Function URLDownloadToFile Lib "urlmon" _ Alias "URLDownloadToFileA" (ByVal pCaller As Long, ByVal szURL As String, _ ByVal szFileName As String, ByVal dwReserved As Long, ByVal lpfnCB As Long) As Long