JohnMC Posted March 8, 2009 Author Posted March 8, 2009 ghetek said: Does anyone have a working example of a file upload with progressbar?This script doesnt have any way of checking progressIndyUK: No it does not as far as i know, check out wininet its your best shot, but i dont see it listed, youll need to read up https://johnscs.com
atomman Posted March 15, 2009 Posted March 15, 2009 (edited) very easy to get this script working! but this seems to break it... this works: $file = 'C:\file.txt' _FtpPutFile($Hand, $file, '/') this doesn't work: $dir = 'C:\' $file = 'file.txt' _FtpPutFile($Hand, $dir & $file, '/') EDIT - there's something else going on (probably something i'm doing wrong) - sometimes i can get it to transfer, sometimes not. passive mode has no effect. Edited March 15, 2009 by atomman
Yashied Posted March 23, 2009 Posted March 23, 2009 (edited) JohnMC said: Great point, i should add this, but i help me out here... are there known issues with some options, most notably the timeout ones, i dont know if im getting this mixed up with a different project, but i remember people complaing about how it never worked right, thats why i never botherdalso should i set these constants within this UDF, and are the values based on the posistion they have in the list on the msdnJohnMC, if you will be interested to take a look at my version of UDF. There is a function _InternetGetOption () and _InternetSetOption. Actually it is in WinINet.au3, but I changed it to make it easier to use directly to FTP.FTP.au3 Edited May 12, 2009 by Yashied My UDFs: Reveal hidden contents iKey | FTP Uploader | Battery Checker | Boot Manager | Font Viewer | UDF Keyword Manager | Run Dialog Replacement | USBProtect | 3D Axis | Calculator | Sleep | iSwitcher | TM | NetHelper | File Types Manager | Control Viewer | SynFolders | DLL Helper Animated Tray Icons UDF Library | Hotkeys UDF Library | Hotkeys Input Control UDF Library | Caret Shape UDF Library | Context Help UDF Library | Most Recently Used List UDF Library | Icons UDF Library | FTP UDF Library | Script Communications UDF Library | Color Chooser UDF Library | Color Picker Control UDF Library | IPHelper (Vista/7) UDF Library | WinAPI Extended UDF Library | WinAPIVhd UDF Library | Icon Chooser UDF Library | Copy UDF Library | Restart UDF Library | Event Log UDF Library | NotifyBox UDF Library | Pop-up Windows UDF Library | TVExplorer UDF Library | GuiHotKey UDF Library | GuiSysLink UDF Library | Package UDF Library | Skin UDF Library | AITray UDF Library | RDC UDF Library Appropriate path | Button text color | Gaussian random numbers | Header's styles (Vista/7) | ICON resource enumeration | Menu & INI | Tabbed string size | Tab's skin | Pop-up circular menu | Progress Bar without animation (Vista/7) | Registry export | Registry path jumping | Unique hardware ID | Windows alignment More...
nugame Posted April 14, 2009 Posted April 14, 2009 Yashied said: JohnMC, if you will be interested to take a look at my version of UDF. There is a function _InternetGetOption () and _InternetSetOption. Actually it is in WinINet.au3, but I changed it to make it easier to use directly to FTP. I am using the latest FTP_EX udf...i believe. Everything works so far but cannot get the _FTPCommand work. is there an example for this function? thaks Dr SherlockAlways a way
microbious Posted June 13, 2009 Posted June 13, 2009 (edited) OOps should have looked into .FTP.au3 _FTPConnect($FTPopen, $IPvalue2, $USERNAMEvalue, $PASSvalue, $PORTvalue) Question to UDF developer. I found this tool 'DLL Export Viewer v1.35' that can read/export sellected DLL functions and i was looking it those you used in your UDF. So i thought that there are plenty of other parameters that i could add to my own UDF's for personal use and maybe for public release later on, but i have one problem. Problem is that in your UDF you are referencing to DLL functions not as i see them. I mean for example FtpPutFile looking at it through FLL Explort viewer shows me that there are several FtpPutFile functions such as: FtpPutFileW FtpPutFileEx FtpPutFileA How in gods name and where did u find FtpPutFile ? Edited June 14, 2009 by lessstoopid
Electon Posted August 26, 2010 Posted August 26, 2010 On 2/10/2009 at 6:36 PM, 'Yashied said: Well done, I used your UDF in their scripts. But why did you not use the functions InternetSetOption (for example, to set the timeout response from the FTP server). Without this script can not answer a long time. In my scripts I have used it. To set the timeout it will look like this: const $INTERNET_OPTION_RECEIVE_TIMEOUT = 6 const $TimeOut = 60 * 1000 ; ms local $WININET_HANDLE = DllOpen('wininet.dll') _InternetSetOptions($hInternet, $INTERNET_OPTION_RECEIVE_TIMEOUT, $TimeOut) func _InternetSetOptions($hInternet, $iOption, $iValue) local $tBuffer = DllStructCreate('int Value') DllStructSetData($tBuffer, 'Value', $iValue) DllCall($WININET_HANDLE, 'int', 'InternetSetOptionW', 'hwnd', $hInternet, 'int', $iOption, 'ptr', DllStructGetPtr($tBuffer), 'int', DllStructGetSize($tBuffer)) $tBuffer = 0 if (@error) or (_WinAPI_GetLastError() > 0) then return SetError(1, 0, 0) endif return SetError(0, 0, 1) endfunc; _InternetSetOptions The following list shows the options that can be set for $iOption: INTERNET_OPTION_CONTEXT_VALUE INTERNET_OPTION_CONNECT_TIMEOUT INTERNET_OPTION_CONNECT_RETRIES INTERNET_OPTION_CONNECT_BACKOFF INTERNET_OPTION_CONTROL_SEND_TIMEOUT INTERNET_OPTION_CONTROL_RECEIVE_TIMEOUT INTERNET_OPTION_DATA_SEND_TIMEOUT INTERNET_OPTION_DATA_RECEIVE_TIMEOUT INTERNET_OPTION_READ_BUFFER_SIZE INTERNET_OPTION_WRITE_BUFFER_SIZE INTERNET_OPTION_USERNAME INTERNET_OPTION_PASSWORD INTERNET_OPTION_PROXY INTERNET_OPTION_USER_AGENT INTERNET_OPTION_RECEIVE_TIMEOUT http://msdn.microsoft.com/en-us/library/ms918381.aspx I would like to use this to set a proxy for my embedded IE. can you show an example of that? also, what is $hInternet?
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