/dev/null Posted November 20, 2006 Posted November 20, 2006 many timesand why don't NOT use the FTP functions of w0uter? __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
friendfox Posted November 20, 2006 Posted November 20, 2006 I needed a function it can download file from a ftp server.The function "INETGET" can do it ,but when download file use "INETGET",it write the target file and write the internet TEMP file at on time too,so caused the computer slowly.(谢谢)THX.The function "INETGET" can do it ,but when download file use "INETGET",it write the target file and write the internet TEMP file at on time too,so caused the computer slowly.
Moderators SmOke_N Posted November 20, 2006 Moderators Posted November 20, 2006 The function "INETGET" can do it ,but when download file use "INETGET",it write the target file and write the internet TEMP file at on time too,so caused the computer slowly.Any reason why your double posting the same post as before? Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.
friendfox Posted November 21, 2006 Posted November 21, 2006 I am from chinese and pool in speak english so "double posting the same post as before" my one scrip download from server use HTTP or FTP with "INETGET" will write target FILE and TEMP file at a same time so will caused computer run slowly.
friendfox Posted November 21, 2006 Posted November 21, 2006 $server = '221.214.33.XXX' $username = 'administrator' $pass = 'pawd' $Open = _FTPOpen('ftp') $Conn = _FTPConnect($Open, $server, $username, $pass) $Ftpp = _FtpgetFile($Conn, 'abc.exe', 'c:\abc.exe') $Ftpc = _FTPClose($Open) $ftpp return 0 and download fail.
/dev/null Posted November 21, 2006 Posted November 21, 2006 (edited) $ftpp return 0 and download fail. according to this post http://www.autoitscript.com/forum/index.ph...st&p=266644 you need to load the DLL, otherwise the FTP UDF will fail. TODO: 3.2.0.1 nothing, it works as is (although the 3.2.0.1 help file states something different !??!) 3.2.x Beta. use DllOpen() to load the DLL. See code below.$dllhandle = DllOpen('wininet.dll'); <<== HERE !! $Open = _FTPOpen('ftp') $Conn = _FTPConnect($Open, $server, $username, $pass) ;$Ftpp = _FtpPutFile($Conn, 'C:\WINDOWS\Notepad.exe', '/somedir/Example.exe') $Ftpp = _FtpGetFile($Conn, 'test.exe', 'c:\test.exe') $Ftpc = _FTPClose($Open) DllClose($dllhandle); <<== HERE !! Cheers Kurt Edited November 21, 2006 by /dev/null __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
friendfox Posted November 21, 2006 Posted November 21, 2006 thanks /dev/null it is run now bug it write the Internet TEMP file too It grieves me
/dev/null Posted November 21, 2006 Posted November 21, 2006 (edited) bug it write the Internet TEMP file too no bug. Flags !! ; =[ADDED THIS]= Const $FTP_TRANSFER_TYPE_ASCII = 0x01 Const $FTP_TRANSFER_TYPE_BINARY = 0x02 Const $INTERNET_FLAG_NO_CACHE_WRITE = 0x4000000 $ftp_flags = $FTP_TRANSFER_TYPE_BINARY + $INTERNET_FLAG_NO_CACHE_WRITE ; =[/ADDED THIS]= $dllhandle = DllOpen('wininet.dll'); $Open = _FTPOpen('ftp') $Conn = _FTPConnect($Open, $server, $username, $pass) $Ftpp = _FtpGetFile($Conn, 'test.exe', 'c:\test.exe',$ftp_flags) ; <<== CHANGE HERE !! $Ftpc = _FTPClose($Open) DllClose($dllhandle); Cheers Kurt Edited November 21, 2006 by /dev/null __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
furso Posted December 7, 2006 Posted December 7, 2006 I cannot get this thing to work at all. i used the example script and modified the server, login and password stuff. but basically, i see it connecting, it then just dis-connects and doesnt transfer any files. i've tried this with 2 diff. ftp servers.. even when i take out the ftp disconnect command. it still does it. if i use a regular ftp client, everything works fine with both servers. i'd post code, but like i said, i'm just using the provided example to test with. Me 2, im a bit new to this so bare with me. im trying to upload files my xbox via ftp. i think it connects but i cannot upload any files, here is the code used to upload $Open = _FTPOpen('Xbox communicator') $server = 'ftp://' & $ftpip $Conn = _FTPConnect($Open, $server, $username, $pass) $Ftpp = _FtpPutFile($Conn, 'C:\WINDOWS\Notepad.exe', $driveletter & "/Example.exe") $Ftpc = _FTPClose($Open) the drive letter is a file name (eg F) and im using notepad as an example
/dev/null Posted December 7, 2006 Posted December 7, 2006 (edited) Me 2, im a bit new to this so bare with me. im trying to upload files my xbox via ftp. i think it connects but i cannot upload any files, here is the code used to upload $Open = _FTPOpen('Xbox communicator') $server = 'ftp://' & $ftpip $Conn = _FTPConnect($Open, $server, $username, $pass) $Ftpp = _FtpPutFile($Conn, 'C:\WINDOWS\Notepad.exe', $driveletter & "/Example.exe") $Ftpc = _FTPClose($Open) the drive letter is a file name (eg F) and im using notepad as an example Me2?? Did you bother to read the posts made in this thread? At least a few directly above yours? Cheers Kurt Edited December 7, 2006 by /dev/null __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
onedayillpay Posted January 2, 2007 Posted January 2, 2007 according to this post http://www.autoitscript.com/forum/index.ph...st&p=266644 you need to load the DLL, otherwise the FTP UDF will fail. $dllhandle = DllOpen('wininet.dll'); <<== HERE !! $Open = _FTPOpen('ftp') $Conn = _FTPConnect($Open, $server, $username, $pass) ;$Ftpp = _FtpPutFile($Conn, 'C:\WINDOWS\Notepad.exe', '/somedir/Example.exe') $Ftpp = _FtpGetFile($Conn, 'test.exe', 'c:\test.exe') $Ftpc = _FTPClose($Open) DllClose($dllhandle); <<== HERE !! oÝ÷ Ûú®¢×¦k&Þ-7êÇ«½êâ³ è è~]z¼±ÊÞj×Â+a¶¬ª[§Ö¥Ûez¥¦sjëh×6 #include <ftp.au3> $server = '63.211.111.36'; ftp://63.211.111.36/cs/63.211.111.36:27015/cstrike/ $username = '326946' $pass = 'password' $dllhandle = DllOpen('wininet.dll'); <<== HERE !! $Open = _FTPOpen('ftp') $Conn = _FTPConnect($Open, $server, $username, $pass) $Ftpp = _FtpPutFile($Conn, 'C:\Snap.bmp', '/cstrike/Snap.bmp') $Ftpc = _FTPClose($Open) DllClose($dllhandle); <<== HERE !!
PerryRaptor Posted January 3, 2007 Posted January 3, 2007 (edited) IP address is good...I pinged it... Question...Is the folder \cstrike\ directly off of the FTP root? Notice I used different "\" than yours "/" may be this is the problem. Question...Can you copy a file to the FTP root? The extra info below is puzzling and leads me to believe your error has something to do with this. $server = '63.211.111.36'; ftp://63.211.111.36/cs/63.211.111.36:27015/cstrike/ For my FTP server, I needed the modification that /dev/null came up with...See bellow. I could not get any type of filename.ext to copy without it. #include <C:\program files\autoit3\include\Ftp.au3> Const $FTP_TRANSFER_TYPE_ASCII = 0x01 Const $FTP_TRANSFER_TYPE_BINARY = 0x02 Const $INTERNET_FLAG_NO_CACHE_WRITE = 0x4000000 $ftp_flags = $FTP_TRANSFER_TYPE_BINARY + $INTERNET_FLAG_NO_CACHE_WRITE $server = '<enter_FTP_IP/URL>' $username = '<enter_your_username>' $pass = '<enter_password>' $dllhandle = DllOpen('wininet.dll') $Open = _FTPOpen('ftp') $Conn = _FTPConnect($Open, $server, $username, $pass) $Ftpp = _FtpPutFile($Conn, 'C:\Windows\NotePad.exe', 'Notepad.exe',$ftp_flags) $Ftpc = _FTPClose($Open) DllClose($dllhandle) Last, this is the example script area...I believe you would receive quick/better support if you would post in the "General Help and Support" area. Edited January 3, 2007 by PerryRaptor
/dev/null Posted January 3, 2007 Posted January 3, 2007 maybe my $server is wrongno folder was created with the snap.bmp in itwhat makes you think that a folder will be created?CheersKurt __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
Zedna Posted January 23, 2007 Posted January 23, 2007 (edited) Hi jerran,I am having similar problems,after getting the filesize by _FTPGetFileSize of an existing file I cant upload anymore by _FtpPutFile.As long I do "_FTPGetFileSize" - tests to non-existings files "_FtpPutFile" works fine - after the first positive occurence of "_FTPGetFileSize" it doesnt work anymore.Look hereThere is FTP UDF from Wouter but with added all functions from this thread. I posted there correction for bug in function _FTPGetFileSize() Edited January 23, 2007 by Zedna Resources UDF ResourcesEx UDF AutoIt Forum Search
Zedna Posted January 23, 2007 Posted January 23, 2007 and why don't NOT use the FTP functions of w0uter?InetGet has one BIG advantage (compared to _FTPGetFile):It has download in background, so we can make progressbars for downloads from FTP. Resources UDF ResourcesEx UDF AutoIt Forum Search
bonebreaker Posted January 25, 2007 Posted January 25, 2007 hi, i tryed FPT upload a few weeks ago and it was working but now the same script failed I guess the problem is with the server service, could anybody suggest a free server service with which i can properly use this ftp function ? My programs:[topic="40019"]Sudoku[/topic], [topic="41258"]Suitcase game & Random jokes[/topic], [topic="41641"]8 Queens[/topic], [topic="41679"]Puzzle Generator[/topic], [topic="42045"]Snake[/topic]My UDFs:[topic="41309"]Prime functions & Prime game[/topic]Other:Fake emailer
/dev/null Posted January 25, 2007 Posted January 25, 2007 hi, i tryed FPT upload a few weeks ago and it was working but now the same script failed I guess the problem is with the server service, could anybody suggest a free server service with which i can properly use this ftp function ?download babyftp server and run it on your machine. It's a single EXE, no installation needed. http://www.pablosoftwaresolutions.com/html...ftp_server.html __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
bonebreaker Posted January 25, 2007 Posted January 25, 2007 download babyftp server and run it on your machine. It's a single EXE, no installation needed. http://www.pablosoftwaresolutions.com/html...ftp_server.htmlThanks that's really a usefull tool for testing, but at the moment i need an ftp server that runs non-stop. My programs:[topic="40019"]Sudoku[/topic], [topic="41258"]Suitcase game & Random jokes[/topic], [topic="41641"]8 Queens[/topic], [topic="41679"]Puzzle Generator[/topic], [topic="42045"]Snake[/topic]My UDFs:[topic="41309"]Prime functions & Prime game[/topic]Other:Fake emailer
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