Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.
Keywords: MSIE IE Internet Explorer InternetExplorer.Application WindowOnTop ParentWindow Focus IE9
oIE = CreateObject("InternetExplorer.Application") oIE.Navigate2("http://www.winbatch.com") While oIE.readyState <> 4 TimeDelay(.5) EndWhile oIE.Toolbar = 0 oIE.StatusBar = 0 oIE.Resizable = 1 oIE.Width = 500 oIE.Height = 125 oIE.Left = 250 oIE.Top = 250 oIE.Visible = 1I have a compiled script that opens an instance of IE, on Windows XP and IE7 or IE8, everything works fine.
Under Win 7 and using IE9, the IE window randomly opens behind the calling application instead of in front of it. I added windowontop(browser.document.title, 1) without any change in behavior.
Any idea what might be causing this?
oIE.document.parentwindow.focusHere is the complete code sample:
oIE = CreateObject("InternetExplorer.Application") oIE.Navigate2("http://www.winbatch.com") While oIE.readyState <> 4 TimeDelay(.5) EndWhile oIE.Toolbar = 0 oIE.StatusBar = 0 oIE.Resizable = 1 oIE.Width = 500 oIE.Height = 125 oIE.Left = 250 oIE.Top = 250 oIE.Visible = 1 ; Set focus to IE window oIE.Document.ParentWindow.Focus()
Article ID: W18134
Filename: WindowOnTop Problem With IE9.txt
File Created: 2011:04:25:10:37:12
Last Updated: 2011:04:25:10:37:12