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 biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Use XMLHTTP to List Remote Directory?

Status
Not open for further replies.

jasonp45

Programmer
Aug 23, 2001
212
US
I want to use the XMLHTTP object to list a directory at a remote FTP site.
I can download a file with this code:

Set oXML = CreateObject("Microsoft.XMLHTTP")
With oXML
.Open "GET", mURL & mDownload_FileName, False, mUserName, mPassword
.send
If .readyState = 4 Then b() = .responseBody
Open mOutput_FileName For Binary Access Write As #1
Put #1, , b()
Close #1
End With

This works fine if I already know the file's name. But I want to list *all*
the files in the target directory. I assume I need something like .Open
"DIR", ...but am not sure of the syntax.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top