Sign in to follow this  
Followers 0
JohnBailey

Wait IE finish loading page

7 posts in this topic

Is there a way to wait for IE to finish loading a page?

WaitIEDone()

Accomplishing that above theoretical script.


A decision is a powerful thing

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

#include <IE.au3> 
_IELoadWait ( ByRef $o_object [, $i_delay = 0 [, $i_timeout = -1]] )oÝ÷ ÚÚºÚ"µÍ]]Ò]Ù]Ü[Û    ][ÝÕÚ[]SX]Ú[ÙI][ÝËBÚ[HÝ]ØÙ]^
    ][ÝÒ[]^Ü][ÝÊH  ÉÝÈ  ][ÝÑÛI][ÝÂTÛY
ML
BÑ[

Edited by Joon

Share this post


Link to post
Share on other sites

#include <IE.au3> 
_IELoadWait ( ByRef $o_object [, $i_delay = 0 [, $i_timeout = -1]] )oÝ÷ ÚÚºÚ"µÍ]]Ò]Ù]Ü[Û    ][ÝÕÚ[]SX]Ú[ÙI][ÝËBÚ[HÝ]ØÙ]^
    ][ÝÒ[]^Ü][ÝÊH  ÉÝÈ  ][ÝÑÛI][ÝÂTÛY
ML
BÑ[

Both are great thank you!!

that IE class is really neat ... Awesome scripting going on here!


A decision is a powerful thing

Share this post


Link to post
Share on other sites

Joon, how do I get the timeout to work. I tried...

#include <IE.au3> 
$o_object = "www.google.com"
If _IELoadWait ($o_object , "",6000 ) = 0 Then
MsgBox(64, "MSG", "didn't work")
ElseIf 1 Then
MsgBox(64, "MSG", "It did work!")
EndIf

A decision is a powerful thing

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

Oh I think I get what's going on...

Here's what I did in full

#include<IE.au3>
$s_Url = "ww.google.com"
$f_tryAttach = 0
$f_visible = 1
$f_wait = 1
$f_takeFocus = 1

_IECreate($s_Url,$f_tryAttach,$f_visible,$f_wait,$f_takeFocus)
Send("house")
Send("{ENTER}")

$o_object = "house - Google Search - Windows Internet Explorer"
If _IELoadWait ($o_object,"",6000) = 0 Then
MsgBox(64, "MSG", "didn't work")
ElseIf 1 Then
MsgBox(64, "MSG", "It did work!")
EndIf
Edited by JohnBailey

A decision is a powerful thing

Share this post


Link to post
Share on other sites

I found that this would work best (probably)

#include <IE.au3>
$oIE = _IECreate ("http://www.google.com")
$oForm = _IEFormGetObjByName ($oIE, "f")
$oQuery = _IEFormElementGetObjByName ($oForm, "q")
_IEFormElementSetValue ($oQuery, "AutoIt IE.au3")
_IEFormSubmit ($oForm)

But I don't understand what _IEFormElementGetObjByName means! I looked at the documentation, but I don't understand.


A decision is a powerful thing

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