Jump to content

IE question


Exact
 Share

Recommended Posts

  • Developers

Have you checked the helpfile for parameters?

#include <IE.au3> 
_IECreate ( [$s_Url = "about:blank" [, $f_tryAttach = 0 [, $f_visible = 1 [, $f_wait = 1 [, $f_takeFocus = 1]]]]] )

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

Have you checked the helpfile for parameters?

#include <IE.au3> 
_IECreate ( [$s_Url = "about:blank" [, $f_tryAttach = 0 [, $f_visible = 1 [, $f_wait = 1 [, $f_takeFocus = 1]]]]] )

yes but how do i know when the page is fully loaded.

I used $f_wait = 0 so it don't waits until the page is loaded.

Now i must know if the page is fully loaded after 3000ms, if this is not it must give a msg or something else.

Edited by Exact
Link to comment
Share on other sites

  • Developers

untested but guess that should be close:

#include<ie.au3>
$h_ie= _IECreate("www.google.com")
_IELoadWait($h_ie,0,3000)
If @error then
    ConsoleWrite('-Timed out' & @crlf)
Else
    ConsoleWrite('+Loaded' & @crlf)
EndIf

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

untested but guess that should be close:

#include<ie.au3>
$h_ie= _IECreate("www.google.com")
_IELoadWait($h_ie,0,3000)
If @error then
    ConsoleWrite('-Timed out' & @crlf)
Else
    ConsoleWrite('+Loaded' & @crlf)
EndIf

Jos

Thanx i wil look tomorrow if it works, i guess it works :)
Link to comment
Share on other sites

Very close, but to use this method, you'll need to tell _IECreate not to wait so that the _IELoadWait gets a chance...

$h_ie= _IECreate("www.google.com", 0, 1, 0)

Alternately, you can use

_IELoadWaitTimeout (3000) ; set default timeout to 3 sec
$h_ie= _IECreate("www.google.com")
If @error = $_IEStatus_LoadWaitTimeout Then ; aka 6
    ConsoleWrite('-Timed out' & @crlf)
Else
    ConsoleWrite('+Loaded' & @crlf)
EndIf

Dale

Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl

MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model

Automate input type=file (Related)

Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded  Better Better?

IE.au3 issues with Vista - Workarounds

SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y

Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead?

Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble

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...