Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations MikeeOK on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MSINET (ftp problem) 1

Status
Not open for further replies.

ASPVBNerd

Programmer
Nov 23, 2005
83
SE
I am just triying to send a file with ftp using msinet The file is never being sent!
If I try doing it with msdos like this put c:\xmlocx\test.xml test.xml then it works.

Code:
Private Sub mnuskickaxml_Click()

    On Error GoTo ErrH
    
    With Inet
        .Cancel
        .AccessType = icUseDefault
        .Protocol = icFTP
        .url = "SUPPORT"
        .UserName = "anonymous"
        .Password = "jaghatardig@nerd.com"
        .RemotePort = 21
        .RequestTimeout = 50
        .Execute , "put c:\xmlocx\test.xml", "test.xml"
        WaitForResponse
        .Execute , "QUIT"
        WaitForResponse
    End With
    Exit Sub
ErrH:
    MsgBox "Error " & Err.Number
End Sub

Private Sub WaitForResponse()
    Do While Inet.StillExecuting
        DoEvents
    Loop
End Sub

Private Sub EndApp()
    Inet.Cancel
    End
End Sub
What could be the problem?
 
...also,

.Execute , "put c:\xmlocx\test.xml", "test.xml"
I think should be:
.Execute , "PUT c:\xmlocx\test.xml /test.xml"

------------
You should search the forum first as these types of questions have been answered a ton of times.
 
Check this out:


thread222-1126722

I hope this helps.



Ron Repp
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top