Jump to content

Why do _IE functions hang with 3.2.12.1 and Vista?


Recommended Posts

I am having problems with _IE functions hanging now that I have switched to 3.2.12.1 - e.g. this code from the _IECreate help page opens the browser, but then the script hangs. No MsgBox comes up.

#include <IE.au3>

$oIE = _IECreate ("http://sourceforge.net", 0, 0)

; Display the innerText on an element on the page with a name of "sfmarquee"

$oMarquee = _IEGetObjByName ($oIE, "sfmarquee")

MsgBox(0, "SourceForge Information", $oMarquee.innerText)

_IEQuit ($oIE)

Another example, _IELinkGetCollection produces an error code 3 on every URL I open with _IECreate, then dies. Error code 3= ($_IEStatus_InvalidDataType) = Invalid Data Type

These were all workin fine before switch. Any suggestions?

Naturally 3.2.12.1 means AutoIt v 3.2.12.1, and I'm using Vista Ultimate SP1.

Edited by vatobeto
Link to comment
Share on other sites

Please see the Vista notes on _IECreate in the helpfile -- place #RequireAdmin at the top of your script.

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

  • 8 months later...

This is boggling. First we are told to add #RequireAdmin to get around the two window problem, then told to remove that and disable UAC otherwise it thinks the page is browser is still loading and never continues.

I got my script to work in vista with

Global $oIE
$oIE = _IECreate("about:blank")
_IELoadWait ($oIE)
if @OSVersion = "WIN_VISTA" Then
    $oIE = _IEAttach("", "instance" ,1)
endif

which means no matter the new window it creates, it attaches to the first instance it finds. This does NOT work if I have #RequireAdmin in my code.

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