PC Review


Reply
Thread Tools Rate Thread

automate FTP

 
 
pete0085
Guest
Posts: n/a
 
      26th Dec 2008
I'm trying to automate a simple FTP batch script and when I run the commands
individually in the command prompt it's not sending over both files, only 1.
I have two "filename".zip files and it's only sending the first.

ftp ftp.server2.com
username
password
put s:\admin\folder\*.zip
quit


 
Reply With Quote
 
 
 
 
David H. Lipman
Guest
Posts: n/a
 
      26th Dec 2008
From: "pete0085" <(E-Mail Removed)>

| I'm trying to automate a simple FTP batch script and when I run the commands
| individually in the command prompt it's not sending over both files, only 1.
| I have two "filename".zip files and it's only sending the first.

| ftp ftp.server2.com
| username
| password
| put s:\admin\folder\*.zip
| quit


Example done in KiXtart

SETCONSOLE("SHOW")
SETCONSOLE("MAXIMIZE")
SETCONSOLE("FOREGROUND")
Color y+/b
cls
$home="D:\local_folder"
$drive=left($home,2)
go $drive
cd $home
$FTPCMD="FTP-CMD.TXT"
Open (1,$FTPCMD,1)
Close(1)
Open (1,$FTPCMD,4)
WriteLine(1,"open server.name.com"+@CRLF)
WriteLine(1,"username"+@CRLF)
WriteLine(1,"password"+@CRLF)
WriteLine(1,""+@CRLF)
WriteLine(1,"lcd $home "+@CRLF)
WriteLine(1,"bin "+@CRLF)
WriteLine(1,"hash "+@CRLF)
WriteLine(1,"prompt "+@CRLF)
WriteLine(1,"put file.zip "+@CRLF)
WriteLine(1,"bye "+@CRLF)
Close(1)
cls
shell "FTP -s:$FTPCMD"
del $FTPCMD


--
Dave
http://www.claymania.com/removal-trojan-adware.html
Multi-AV - http://www.pctipp.ch/downloads/dl/35905.asp


 
Reply With Quote
 
Pegasus \(MVP\)
Guest
Posts: n/a
 
      26th Dec 2008

"pete0085" <(E-Mail Removed)> wrote in message
news:92DA9AD7-B1F2-48FC-B8C2-(E-Mail Removed)...
> I'm trying to automate a simple FTP batch script and when I run the
> commands
> individually in the command prompt it's not sending over both files, only
> 1.
> I have two "filename".zip files and it's only sending the first.
>
> ftp ftp.server2.com
> username
> password
> put s:\admin\folder\*.zip
> quit


See the reply you received the the VB Script newsgroup, then have a look at
this site to see the merits of cross-posting vs. multi-posting:
http://www.blakjak.demon.co.uk/mul_crss.htm. Cross-posting is fine,
multi-posting causes duplication of effort.


 
Reply With Quote
 
Barry Schwarz
Guest
Posts: n/a
 
      27th Dec 2008
On Fri, 26 Dec 2008 09:27:01 -0800, pete0085
<(E-Mail Removed)> wrote:

>I'm trying to automate a simple FTP batch script and when I run the commands
>individually in the command prompt it's not sending over both files, only 1.
>I have two "filename".zip files and it's only sending the first.
>
>ftp ftp.server2.com
>username
>password


prompt

>put s:\admin\folder\*.zip


Use mput

>quit
>


--
Remove del for email
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to automate with vb6 - can automate two lines but no more :-( =?Utf-8?B?UGhvZW5peDFfdWs=?= Microsoft Powerpoint 1 14th Aug 2006 04:34 PM
Automate without add-ins Rob Oldfield Microsoft Excel Misc 3 21st Oct 2005 07:33 PM
Automate Add-in =?Utf-8?B?R2FyeSdzIFN0dWRlbnQ=?= Microsoft Excel Misc 4 20th Jun 2005 02:12 AM
help with automate please =?Utf-8?B?c2FyYQ==?= Microsoft Excel Worksheet Functions 2 24th Feb 2004 11:31 PM
I need to automate this.... Jason Walter Microsoft Access Getting Started 1 2nd Oct 2003 05:38 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:58 AM.