incepator Posted August 21, 2013 Posted August 21, 2013 (edited) Hello, I have a question with a problem... I using this part of the script: BinaryToString(InetRead("www.site.com", 1)) Problem is function "InetRead", because not wait for page load. Some items appear in a few seconds loading site... Thanks, and sorry for bad my english, i`m from Romania. Edited August 21, 2013 by incepator
hannes08 Posted August 21, 2013 Posted August 21, 2013 Hi,did you try using the _IE*() functions? Regards,Hannes[spoiler]If you can't convince them, confuse them![/spoiler]
Gianni Posted August 21, 2013 Posted August 21, 2013 Hi incepator maybe you should use InetGet() instead it seems a better choice for your case. take a look to the example in the help, it also has a default parameter that says "Wait until the download is complete before continuing" bye Chimp small minds discuss people average minds discuss events great minds discuss ideas.... and use AutoIt....
incepator Posted August 21, 2013 Author Posted August 21, 2013 (edited) @hannes08 Yes..._IE() functions is a alternative, but is not perfect, because request IE.... Other alternative, using BinaryToString, is not possible ? @Pincopanco I use the InetGet() function, but the result was the same oh the InetRead Edited August 21, 2013 by incepator
Solution dragan Posted August 21, 2013 Solution Posted August 21, 2013 how about this: Local $webURL = 'http://www.autoitscript.com/site' Local $oHTTP = ObjCreate("winhttp.winhttprequest.5.1") $oHTTP.Open("GET",$webURL) $oHTTP.Send() $oHTTP.WaitForResponse() Local $HTMLSource = $oHTTP.Responsetext ConsoleWrite($HTMLSource & @CRLF) $oHTTP = 0 incepator 1
0xdefea7 Posted August 21, 2013 Posted August 21, 2013 Or $hDownload = InetGet("www.site.com", @TempDir & "`1234.dat", 1, 1) Do Sleep(250) Until InetGetInfo($hDownload, 2) $sData = FileRead(@TempDir & "\~1234.dat") ConsoleWrite($sData & @CRLF)
incepator Posted August 21, 2013 Author Posted August 21, 2013 (edited) Thanks @dragan, work this function... Edited September 4, 2013 by incepator
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