Re: VBscript for FTP upload
- From: "NickHK" <TungCheWah@xxxxxxxxxxx>
- Date: Wed, 11 Jul 2007 12:22:49 +0800
It seems that Excel needs to "know" that you are currently in/able to make
an FTP session. As such you can fake a download, just to bring up the login
dialog.
After that, the .SaveAs will work.
I could not get a direct .SaveAs to execute with the initial login step as
suggested by:
http://www.mrexcel.com/archive2/53600/62315.htm
Maybe related to recent IE updates about setting a username/pw in the URL,
but I thought related to HTTP rather FTP, but may be both:
On Error Resume Next
'Not existent file, just to bring up the FTP login dialog
Workbooks.Open Filename:="ftp://ftp.YOURSITE.com/NotThere.csv"
On Error GoTo 0
'Once you're logged into the FTP site, it has no problem saving the file.
Active***.SaveAs "ftp://ftp.YOURSITE.com/SomeFile.csv", xlCSV
NickHK
"7857Acimovic" <7857Acimovic@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:287B888E-3980-42D2-B522-EEFF1CBA369D@xxxxxxxxxxxxxxxx
I am a VB beginner and I don't know how to export a CVS file to a FTPserver.
Right now I have excel work*** that is converted into a CVS file andcode
placed in the parent folder. What I don't know how to write is the VB
for uploading the CVS file to a ftp server. Anyone out there got ideas?
Thanks in advance,
Srdjan
.
- Prev by Date: Re: Best approach for broadcasting a notifivation to another progr
- Next by Date: Re: public global constants
- Previous by thread: Problem with Deleting Folders and MoveFileEx
- Next by thread: How can I change to code to avoid error
- Index(es):