Article ID: 171828
Article Last Modified on 11/18/2003
170365 : INFO: Visual Studio 97 Service Packs - What, Where, and Why
171554 : INFO: Visual Basic 5.0 Fixes in Visual Studio 97 Service Pack 2
Private Sub Inet1_StateChanged(ByVal State As Integer)
Dim strMess As String ' Message variable.
Select Case State
' ... Other cases not shown.
Case icError ' 11
' Get the Text of the error.
strMess = "ErrorCode: " & Inet1.ResponseCode & " : " &
Inet1.ResponseInfo
End Select
End Sub
Private Sub Command1_Click()
' download FTP files
Dim b() As Byte
Dim strURL As String
' Set the strURL to a valid address.
strURL = "FTP://GenericServer/FileToDownload.bin"
' Retrieve the file as a byte array.
b() = Inet1.OpenURL(strURL, icByteArray)
' ** create directory on your machine with directory target
Open "C:\Target\FileToDownload.bin" For Binary Access _
Write As #1
Put #1, , b()
Close #1
End Sub
Keywords: kbbug kbfix kbvbp500sp2fix kbvs97sp2fix KB171828