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

I need to call ftp from within a tcl procedure

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
0
0
Hi!


I am held up with a problem. I need to connect to a ftp server to send a file from within a tcl process.


set {exec /usr/bin/ftp] does not seem to work.

can someone sendme a script from which i can get a ftp prompt so that I can open a server machine.



thanks in advance



raj
 
I use the -s option in ftp:
exec ftp -s:ftp2.txt -i
where ftp2.txt contains the login and put or get information Bob Rashkin
rrashkin@csc.com
 
Another possibility is to use the ftp package that's provided as part of tcllib, the Tcl Standard Library. Documentation on the ftp package is available at
Tcllib is part of the standard Tcl distribution, and you can also pick up the latest version of it from You can find out more information about tcllib at the SourceForge page, and from the Tcl'ers Wiki ( at its main tcllib page, - Ken Jones, President
Avia Training and Consulting
866-TCL-HELP (866-825-4357) US Toll free
415-643-8692 Voice
415-643-8697 Fax
 
The ftp package (as avia mentioned) is the best solution IMO. It is tcl native and very easy to use.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top