Kan ikke få FTP upload til at virke
Jeg har flg. kode, men kan simpelthen ikke få det til at virke, der kommer INTET op på serveren, og programmet giver heller ingen fejl :(Function putPicture(fName as String)
With Inet1
.AccessType = icUseDefault
.Protocol = icFTP
.RemotePort = 21
.URL = "xxx"
.UserName = "xxx"
.Password = "xxx"
sLocalFile = App.Path & "\" & fName
sRemoteFile = "/public_html/images/" & fName
.Execute , "PUT " & sLocalFile & " " & sRemoteFile
Do While .StillExecuting And Not bError
DoEvents
Loop
If bError Then
MsgBox "Fejl under upload!" & vbCrLf & _
"Response Code: " & .ResponseCode & vbCrLf & _
"Response Info: " & .ResponseInfo
End If
End With
End Function
Private Sub Inet1_StateChanged(ByVal State As Integer)
If State = icError Then
bError = True
End If
End Sub
