Works for all files:
VB Code:
Option Explicit Public i As Long Private Sub Form_Load() On Error GoTo errorHandeler Dim strURL As String Dim bData() As Byte Dim intFile As Integer strURL = "http://www.someSite.com/someFile.jpg" intFile = FreeFile() bData() = Inet1.OpenURL(strURL, icByteArray) Open "C:\someFile.jpg" For Binary Access Write As #intFile Put #intFile, , bData() Close #intFile Exit Sub errorHandeler: End Sub




Reply With Quote