Sign in to follow this  
Followers 0
qwertylol

ftp access

2 posts in this topic

I got the ftp functions from here

http://www.autoitscript.com/forum/index.ph...tpFileFindFirst

and then I arranged it so here:

#include <ftp.au3>

Dim $s_Agent = "alarm"          ;- Random name. ( like "myftp" )
Dim $l_AccessType   ;- I dont got a clue what this does.
Dim $s_ProxyName    ;- ProxyName.
Dim $s_ProxyBypass  ;- ProxyByPasses's.
Dim $l_Flags        ;- Special flags.

Dim $l_InternetSession  ;- The Long from _FTPOpen()
Dim $s_ServerName = "ftp.ftp.com"          ;- Server name/ip.
Dim $s_Username = "username"    ;- Username.
Dim $s_Password = "password"            ;- Password.
Dim $i_ServerPort = ""      ;- Server port ( 0 is default (21) )
Dim $l_Service          ; I dont got a clue what this does.
Dim $l_Flags            ;- Special flags.
Dim $l_Context          ;- I dont got a clue what this does.

Dim $l_FTPSession   ;- The Long from _FTPConnect()
Dim $s_LocalFile = "a.txt" ;- The local file.
Dim $s_RemoteFile = "a.txt"     ;- The remote Location for the file.
Dim $l_Flags        ;- Special flags.
Dim $l_Context      ;- I dont got a clue what this does.








Dim $ftp

$l_InternetSession = _FTPOpen($s_Agent, $l_AccessType = 1, $s_ProxyName = '', $s_ProxyBypass = '', $l_Flags = 0)
$l_FTPSession = _FTPConnect($l_InternetSession, $s_ServerName, $s_Username, $s_Password, $i_ServerPort = 0, $l_Service = 1, $l_Flags = 0, $l_Context = 0 )
_FTPPutFile($l_FTPSession, $s_LocalFile, $s_RemoteFile, $l_Flags = 0, $l_Context = 0)

yet it doesn't work. what went wrong?

Share this post


Link to post
Share on other sites



Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0