Israel Posted July 29, 2015 Share Posted July 29, 2015 Hello,I'm creating a function that connects to an active IE window. From beginning it worked, but some applications are emerging that does not connect. Displays the error:-> IE.au3 T3.0-1 Warning function from _IEAttach, $ _IESTATUS_NoMatchDoes anyone know how to help me?Func _ConnectWindow() $oie = _IEAttach(WinGetHandle(""), "hwnd") If @error Then Return False Else Return $oie Endif endFunc Link to comment Share on other sites More sharing options...
JohnOne Posted July 29, 2015 Share Posted July 29, 2015 Perhaps because WinGetHandle("") is not an IE window. AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
Israel Posted July 29, 2015 Author Share Posted July 29, 2015 is a window ie yes. This function is associated with a shortcut key. Link to comment Share on other sites More sharing options...
JohnOne Posted July 29, 2015 Share Posted July 29, 2015 Please say how you are certain, and what it has to do with shortcut keys. AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
Israel Posted July 29, 2015 Author Share Posted July 29, 2015 I start my tool after active ie a window and squeeze the button to connect it Link to comment Share on other sites More sharing options...
JohnOne Posted July 29, 2015 Share Posted July 29, 2015 So you are 100% sure that giving no title returns the active window handle, and not the top of z-order handle? AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
Israel Posted July 29, 2015 Author Share Posted July 29, 2015 Not 100%, but I just wanted to understand why it works for some and not for others and these windows contains titles. It is necessary to connect in a open and active window ie, ie until access I I do not know the title of it Link to comment Share on other sites More sharing options...
JohnOne Posted July 29, 2015 Share Posted July 29, 2015 You should try to use "[ACTIVE]" as the title parameter. AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
Israel Posted July 29, 2015 Author Share Posted July 29, 2015 unsuccessfully Link to comment Share on other sites More sharing options...
JohnOne Posted July 29, 2015 Share Posted July 29, 2015 Out of ideas, works perfectly fine here. AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
Gianni Posted July 29, 2015 Share Posted July 29, 2015 have a look to Example 5 in the help of the _IEAttach() function. Chimp small minds discuss people average minds discuss events great minds discuss ideas.... and use AutoIt.... Link to comment Share on other sites More sharing options...
Israel Posted July 30, 2015 Author Share Posted July 30, 2015 JohnOne, I can not send you the application I'm trying to access is private because of my service, but with banking sites do not work either. Can there be any network lock?Chimp, the correct instance does not help me because I can have more than one open window and have to plug in a specifies. Link to comment Share on other sites More sharing options...
JohnOne Posted July 30, 2015 Share Posted July 30, 2015 I don't believe networks have anything to do with getting a handle to a local active window. AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
Israel Posted July 30, 2015 Author Share Posted July 30, 2015 already I tried in every way and I'm doing tests with bank site. I always back the error in the match Link to comment Share on other sites More sharing options...
Israel Posted July 30, 2015 Author Share Posted July 30, 2015 I changed my function to the function below:Local $a = WinGetHandle("[Active]") ConsoleWrite($a & @CRLF) $oie = _IEAttach(WinGetHandle("[Active]"), "hwnd") If @error Then Return False EndIf Return TrueAnd I did the tests at the following sites:http://www.bb.com.br/portalbb/home29,116,116,1,1,1,1.bbhttps://www.itau.com.br/http://www.caixa.gov.br/Paginas/home-caixa.aspxall sites above worked, but it did not work at the site below:http://mercantildobrasil.com.br/BeneficiarioINSS/Paginas/default.aspxI did the tests with banking sites to maintain a standard. They know why it works in some and not in others? The handle that returns is the same for all, which leaves the error without any sense. Link to comment Share on other sites More sharing options...
JohnOne Posted July 30, 2015 Share Posted July 30, 2015 Once again, works fine here.#include <IE.au3> Sleep(3000) ; Time to activate window. $oie = _IEAttach(WinGetHandle("[Active]"), "hwnd") If @error Then Exit MsgBox(0,0,0) EndIf _IENavigate($oie, "https://www.google.co.uk/") AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
Israel Posted July 31, 2015 Author Share Posted July 31, 2015 JohnOne,My script has to connect to an active window and get the url that window. So I created this function. The example above works sent me on the websites of banks? because for me does not work here. Link to comment Share on other sites More sharing options...
JohnOne Posted July 31, 2015 Share Posted July 31, 2015 IE had this page open http://mercantildobrasil.com.br/BeneficiarioINSS/Paginas/default.aspx it works just fine. AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
Israel Posted July 31, 2015 Author Share Posted July 31, 2015 JohnOne,I did the tests here and there is a plugin that makes the lock on my machine. I apologize for the inconvenience and appreciate the dedication to help. Thank you. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now