sundeep Posted April 2, 2009 Share Posted April 2, 2009 Hi,I have went through the forum thoroughly from the past two days and most of them are pointing to the following threads: http://www.autoitscript.com/forum/index.ph...6246&hl=ftphttp://www.autoitscript.com/forum/index.php?showtopic=12473But when I compile and run these scripts, I get a large list of errors :"C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3(1,10) : ERROR: can't open include file "FTP.au3"#include "FTP.au3"~~~~~~~~~^C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3(9,27) : ERROR: _FTPOpen(): undefined function.$Open = _FTPOpen("MyFTP",0)~~~~~~~~~~~~~~~~~~~~~~~~~~^C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3(11,57) : ERROR: _FTPConnect(): undefined function.$Conn = _FTPConnect($Open, $server, $username, $pass, 21)~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3(14,69) : ERROR: _FtpPutFile(): undefined function.$Ftpp = _FtpPutFile($Conn, "C:\TEST.txt", "/public_html/Autoit_Test")~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3(18,24) : ERROR: _FTPClose(): undefined function.$Ftpc = _FTPClose($Open)~~~~~~~~~~~~~~~~~~~~~~~^C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3 - 5 error(s), 0 warning(s)"I installed the latest beta version and tried compiling the code using it with the same set of errors.I clearly understand that I am making a major mistake but can someone point it out please.This is the exact code I am trying to compile:#include <FTP.au3>$server = 'ftp://My Server Ip'$username = 'anonymous'$pass = '*****'$Open = _FTPOpen('MyFTP')$Conn = _FTPConnect($Open, $server, $username, $pass)$Ftpp = _FTPPutFile($Conn, 'doc.txt', '/doc2.txt')MsgBox(0,0,$Ftpp);$FtpMD = _FTPMakeDir($Conn, "/asdf")$Ftpc = _FTPClose($Open)Will the above code work ? I have downloaded a freeware ftp server, which uses the username and password as "anonymous" and "*****" by default and port as 21. I have installed both the client and the server on my system.Please do not point me to any threads because that is what I have done from the past 2 days with no satisfactory results I have installed the beta version also and I have tried running the script with it with no luck :-(, assuming the standard version v 3.0.0.0 does not include the library ftp.au3.Thanks in advance for all the help!Regards,Sun. Link to comment Share on other sites More sharing options...
sundeep Posted April 2, 2009 Author Share Posted April 2, 2009 Hi,I have went through the forum thoroughly from the past two days and most of them are pointing to the following threads: http://www.autoitscript.com/forum/index.ph...6246&hl=ftphttp://www.autoitscript.com/forum/index.php?showtopic=12473But when I compile and run these scripts, I get a large list of errors :"C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3(1,10) : ERROR: can't open include file "FTP.au3"#include "FTP.au3"~~~~~~~~~^C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3(9,27) : ERROR: _FTPOpen(): undefined function.$Open = _FTPOpen("MyFTP",0)~~~~~~~~~~~~~~~~~~~~~~~~~~^C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3(11,57) : ERROR: _FTPConnect(): undefined function.$Conn = _FTPConnect($Open, $server, $username, $pass, 21)~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3(14,69) : ERROR: _FtpPutFile(): undefined function.$Ftpp = _FtpPutFile($Conn, "C:\TEST.txt", "/public_html/Autoit_Test")~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3(18,24) : ERROR: _FTPClose(): undefined function.$Ftpc = _FTPClose($Open)~~~~~~~~~~~~~~~~~~~~~~~^C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3 - 5 error(s), 0 warning(s)"I installed the latest beta version and tried compiling the code using it with the same set of errors.I clearly understand that I am making a major mistake but can someone point it out please.This is the exact code I am trying to compile:#include <FTP.au3>$server = 'ftp://My Server Ip'$username = 'anonymous'$pass = '*****'$Open = _FTPOpen('MyFTP')$Conn = _FTPConnect($Open, $server, $username, $pass)$Ftpp = _FTPPutFile($Conn, 'doc.txt', '/doc2.txt')MsgBox(0,0,$Ftpp);$FtpMD = _FTPMakeDir($Conn, "/asdf")$Ftpc = _FTPClose($Open)Will the above code work ? I have downloaded a freeware ftp server, which uses the username and password as "anonymous" and "*****" by default and port as 21. I have installed both the client and the server on my system.Please do not point me to any threads because that is what I have done from the past 2 days with no satisfactory results I have installed the beta version also and I have tried running the script with it with no luck :-(, assuming the standard version v 3.0.0.0 does not include the library ftp.au3.Thanks in advance for all the help!Regards,Sun. Link to comment Share on other sites More sharing options...
jvanegmond Posted April 2, 2009 Share Posted April 2, 2009 In the second topic you posted (this: http://www.autoitscript.com/forum/index.ph...473&hl=FTP) you download FTP.au3 and you place FTP.au3 in the same directory as your script. Problem solved.ERROR: can't open include file "FTP.au3"Means the file can't be opened: For example when it doesn't exist. github.com/jvanegmond Link to comment Share on other sites More sharing options...
nobbe Posted April 2, 2009 Share Posted April 2, 2009 search for ftp.au3 on the forum and include it in your directory (of your main script file)"C:\Documents and Settings\sundeepl\Desktop\FOXTEL\FTP_Ex.au3(1,10) : ERROR: can't open include file "FTP.au3"#include "FTP.au3" Link to comment Share on other sites More sharing options...
sundeep Posted April 2, 2009 Author Share Posted April 2, 2009 Thanks guys for now...I am trying to meddle with it.... , I may bother you again... Regards, Sun. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now