Download from web [RESOLVED]
HI all,
I have a webpath say: www.webserver.com/getfile.asp
How to download the resulting htm file thru vb.net?
in vb6 i used to do the following:
VB Code:
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
Public Function DownloadFile(ByVal URL As String, ByVal LocalFilename As String) As Boolean
Dim lngRetVal As Long
lngRetVal = URLDownloadToFile(0, URL, LocalFilename, 0, 0)
If lngRetVal = 0 Then DownloadFile = True
End Function
pls guide