Jump to content

Ie Auto Question


kmps
 Share

Recommended Posts

anybody can tell me how to confirm a web page had been 100% loaded?

#Include <IE.au3>

$s_URL = "http://www.google.com"

$o_object = ObjCreate("InternetExplorer.Application")

If IsObj($o_object) Then

$o_object.visible = 0

$o_object.navigate ($s_URL)

While _IEGetProperty($o_object, "busy") or _

((_IEGetProperty($o_object, "readyState") <> "complete") and (_IEGetProperty($o_object, "readyState") <> 4))

Sleep(100)

WEnd

_IELoadWait($o_object)

; $o_object.visible = $f_visible

EndIf

Msgbox(0,"","LOADED")

$o_object.visible = 1

Link to comment
Share on other sites

I tried using the code to test something, and I get a error.

$s_oname = ObjName($0_object)

^ERROR

Error: Variable used without being declared

HI,

hmmh works fine for me.

So long,

Mega

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Link to comment
Share on other sites

  • Moderators

#Include <IE.au3>

$s_URL = "http://www.google.com"

$o_object = ObjCreate("InternetExplorer.Application")

If IsObj($o_object) Then

$o_object.visible = 0

$o_object.navigate ($s_URL)

While _IEGetProperty($o_object, "busy") or _

((_IEGetProperty($o_object, "readyState") <> "complete") and (_IEGetProperty($o_object, "readyState") <> 4))

Sleep(100)

WEnd

_IELoadWait($o_object)

; $o_object.visible = $f_visible

EndIf

Msgbox(0,"","LOADED")

$o_object.visible = 1

Why in the world would you do all that when you could just use:

#Include <IE.au3>

$oIE = _IECreate()
_IENavigate($oIE, "http:\\www.google.com")
;The script will not continue until the webpage is finished loading.
MsgBox(0, "", "Finished Loading")
Edited by big_daddy
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...