Jump to content

Recommended Posts

Posted

Paul, Thanks for the analysis, but can you provide a reproducer?

I just tested using _IEAttach on Vista Untimate with IE8 and it worked just as expected.

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

Posted

Dale,

I just installed IE8 on a Vista Home Premium machine. IEAttach now fails (no match). The subject application worked fine under Vista with IE7.

I have Vista Premium 64, IE8 and attach works fine for me . . .

Posted (edited)

Whew -- it took a while to produce a reproducer of the IEAttach problem, but I believe I've done it.

#include <WindowsConstants.au3>
#include <GUIConstantsEx.au3>
#include <Constants.au3>
#include <IE.au3>
AutoItSetOption ('MustDeclareVars', 1);Require explicit variable declaration
AutoItSetOption ('WinTitleMatchMode', 2);Match any substring in title

Local $Title = StringStripWS (InputBox ("IE Attach Test", "Enter title"), 3)

Local $Handle =  WinGetHandle ($Title)

If Not $Handle Then
   MsgBox ($MB_ICONEXCLAMATION + $MB_TOPMOST, "IE Attach", $Title & " window not found.")
   Exit
EndIf

Local $oIE = _IEAttach ($Title, "Embedded")
If @error Then
   MsgBox ($MB_ICONEXCLAMATION + $MB_TOPMOST, "IE Attach", "Unable to attach to " & $Title)
   Exit
Else
   MsgBox ($MB_ICONEXCLAMATION + $MB_TOPMOST, "IE Attach", "Successful attach to " & $Title)
EndIf

$oIE = 0

1. Open the AutoIt Help file, run this script, and type in "AutoIt Help". The IEAttach should be successful.

2. Open Windows Mail. Show the Preview pane. Run this program, type in "Windows Mail" and the IEAttach may be successful, but for me, almost always gets a COM error, as I described in the earlier post. Again, I suspect IE8, but now that I think about it, other updates were installed along with IE8. I only know that this has worked impeccably for the last several months.

The problem was difficult to reproduce because the actual AutoIt application is very large, and attaches to an embedded IE in a proprietary corporate application which no one else would have. I discovered the same problem with Windows Mail simply by trial and error.

If I boot from my backup, which does NOT include IE8 and Tuesday's other updates, this script attaches to Windows Mail just fine. Moreover, if you run this script on XP, it attaches to Outlook Express just fine. I have had to struggle (rather significantly) with Vista's UIPI in other arenas, but I don't envision a solution here if it is in fact related to UIPI.

I would appreciate it if someone else could test this on their machine.

Again, your feedback would be greatly appreciated.

Paul

P.S. I forgot to add that it makes no difference if the script is compiled and "Run As Adiministrator". The COM error still occurs.

Edited by pdaughe
Posted

Thanks for the additional analysis.

I simply need you to be explicit about the failure that you receive. What is the message? When does it occur? Is it always the same?

Thanks,

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

Posted

Thanks for the additional analysis.

I simply need you to be explicit about the failure that you receive. What is the message? When does it occur? Is it always the same?

Thanks,

Dale

Dale, it's exactly as I mentioned in post #20: the statement:

$oIE.document.parentwindow

is where the COM error occurs. Running under ScitTE, the error handler displays a message box, this is followed by the $_IEStatus_NoMatch return from _IEAttach.

Yes, it is ALWAYS the same.

I mentioned I haven't tested this yet under XP, and I haven't. But I just received an e-mail from one of the application's users that it is no longer working -- and guess what, that user just clicked on the IE icon this morning and was greeted by the IE8 setup. The user is running Windows XP Pro. That still doesn't confirm, beyond the shawdow of any doubt, that IE8 is indeed the culprit, but that gives me a fairly high-degree of confidence that it is.

Based on that user report, if you run the sample I posted on XP with IE8, you should experience the COM error.

And, did you observe that behavior with WinTitleMatchMode that I described? I just can't believe there is a problem in AutoIt like that because surely by now it would have been reported, which again, makes me question my setup.

I appreciate your attention to this problem. I'm anxious, as any developer naturally is, to find out what's going on here. ^_^

Paul

P.S. By the way, I have to go out with my wife for the next three hours so I won't be on the forum until after that.

Posted

I looked back through your posts. You said you got a COM error, but you never posted what it is EXACTLY (I can tell you are a good enough coder to know that the exact text means something - perhaps you thought you had posted it already...). That is what I am asking for. Ever if I try your code and get an error there is not guarantee that it is the same. Please post the additional detail - it is important.

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

Posted

I looked back through your posts. You said you got a COM error, but you never posted what it is EXACTLY (I can tell you are a good enough coder to know that the exact text means something - perhaps you thought you had posted it already...). That is what I am asking for. Ever if I try your code and get an error there is not guarantee that it is the same. Please post the additional detail - it is important.

Dale

Sorry, Dale -- the COM error description is:

Access Denied", The requested action with this object has failed, Error code = 2208

Posted

If you run it from SciTe you'll get the full error in a form you can cut and paste it. If it comes up in a message box, use the AutoIt windows Info tool to get it all. If it tells you the error line number is -1, run the .au3 file instead of a compiled exe.

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

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
  • Recently Browsing   0 members

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