Exit Posted July 26, 2011 Share Posted July 26, 2011 I have a problem with the {Browser_Home} key. Here a reproducer. $state = @SW_RESTORE if MsgBox(4+262144,"",@lf & "Browser Minimize ?" & @lf,0) = 6 Then $state = @SW_MINIMIZE For $i = 1 To 3 Send("{BROWSER_HOME}") Sleep(500) WinSetState("[active]", "", $state) Next MsgBox(262144,"",@lf & "Check number of browser windows" & @lf,0) Just let it run 2 times. First run with "yes". Second run with "No". On first run (minimize), there are 3 browser instances. On second run (restore), there is only 1 browser instance. Does anybody has an explanation? What happens when pressing the real "Browser Home" key? I cannot test it due to absence of such a key on my keyboard. Anybody knows where the definition for this key can be read in the registry? App: Au3toCmd UDF: _SingleScript() Link to comment Share on other sites More sharing options...
bogQ Posted July 26, 2011 Share Posted July 26, 2011 (edited) edit:Explanation if page is open and active it will redirect it to homepage(already on homepage makes no diffrance) if page is open but not active (in focus) it will open new page if page dont exsist it will open new page. if you send it too fast youl newer know how many wins youl get, for example from your script i got 1 win instead 3 and instead 2 that whas your result Alternative #include <IE.au3> For $i = 1 To 5 $oIE = _IECreate () _IEAction($oIE, "home") Next Edited July 26, 2011 by bogQ TCP server and client - Learning about TCP servers and clients connectionAu3 oIrrlicht - Irrlicht projectAu3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related) There are those that believe that the perfect heist lies in the preparation.Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost. Link to comment Share on other sites More sharing options...
Exit Posted July 26, 2011 Author Share Posted July 26, 2011 Thanks for your reply. My problem is that I have to use {Browser_Home} key. _IECreate is no alternative. The reproducer was only meant to show that the key sometimes opens a new window and sometimes docks to a exiting instance as new tab or sometimes does nothing. So I digged a little and found a difference when using different show-codes. I want to force the key to open a new window, but I found no registry entry to manipulate that behaviour. Perhaps somebody knows. App: Au3toCmd UDF: _SingleScript() Link to comment Share on other sites More sharing options...
jvanegmond Posted July 26, 2011 Share Posted July 26, 2011 Thanks for your reply. My problem is that I have to use {Browser_Home} key. _IECreate is no alternative. The reproducer was only meant to show that the key sometimes opens a new window and sometimes docks to a exiting instance as new tab or sometimes does nothing. So I digged a little and found a difference when using different show-codes. I want to force the key to open a new window, but I found no registry entry to manipulate that behaviour. Perhaps somebody knows. Wild guess, but try to: Run("cmd /c start http://") It works with Chrome, don't know about Firefox, Opera or IE. github.com/jvanegmond Link to comment Share on other sites More sharing options...
bogQ Posted July 26, 2011 Share Posted July 26, 2011 (edited) with HotKeySet i think you can still click the button and force open new win. btw, where is {Browser_Home} key located on kboard? Edited July 26, 2011 by bogQ TCP server and client - Learning about TCP servers and clients connectionAu3 oIrrlicht - Irrlicht projectAu3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related) There are those that believe that the perfect heist lies in the preparation.Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost. Link to comment Share on other sites More sharing options...
Exit Posted July 26, 2011 Author Share Posted July 26, 2011 (edited) btw, where is {Browser_Home} key located on kboard? usually above the function keys (F1-F12) on a multimedia keyboard.Sometimes it is labeled "WWW". Edited July 26, 2011 by forumer100 App: Au3toCmd UDF: _SingleScript() 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