Excel VbA FTP Transfers

  • Thread starter Thread starter E.Anderegg
  • Start date Start date
E

E.Anderegg

Hello,
I need for a small project to retrieve a file via ftp from the internet,
process it with Excel an save it back to the FTP site. How can I do that
with vba??
I tried to create a link in Explorer to that ftp site, but this does not
work, so I'm looking for a more programmatic solution.
Any help is much appreciated!!

Ernst
 
For the download side, have a look at this very simple API call:

Private Declare Function URLDownloadToFile Lib "urlmon" Alias _
"URLDownloadToFileA" (ByVal pCaller As Long, ByVal strURL As String, _
ByVal strFileName As String, ByVal dwReserved As Long, _
ByVal lpfnCB As Long) As Long

Usage:

if URLDownloadToFile(0, strFullURL, strLocation, 0, 0) = Then 'successful
download took place

Robin Hammond
www.enhanceddatasystems.com
Check out our XspandXL add-in
 
Back
Top