Upload a file with FTP

edtFTPnet is a cool FTP library for .Net released under the LGPL.

import clr clr.AddReference('edtFTPnet')

from EnterpriseDT.Net.Ftp import *

Conn = FTPClient("127.0.0.1") Conn.Login( "username", "password") Conn.ChDir("/targetdir/") Conn.TransferType = FTPTransferType.ASCII Conn.ConnectMode = FTPConnectMode.PASV Conn.Put("kirbybase.py", "kirbybase.txt") Conn.Quit

Back to Contents.