Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

InternetExplorer.Application help

Status
Not open for further replies.
Joined
Jul 29, 2005
Messages
136
Location
PT
Hi,

I have an HTML page with code to automate InternetExplorer.Application. In the code I create the object and navigate to a file/page. This page (which I do not control) will then navigate to another url. When this happen I want to close the window browser I just created.

//Defined Globally
var oIE = new ActiveXObject("InternetExplorer.Application");

//Defined inside a function

oIE.Visible = false;
oIE.Width = 0;
oIE.Height = 0;
oIE.Resizable = true;
oIE.Navigate('url');


while (oIE.LocationUrl != "{
// I need to wait ..... until the url I just opened is changed
}

oIE.Quit()



Problem: The opened page doen´t work well. It only works if the user clicks on the page. I think the first page stay in a loop maybe due to the while cycle...

Is there any way to control this? Is it possible to use Internet.Application events?

Thank you
 
Hi,

But is it possible to use that event in javascript, despite creating the object with the new ActiveXObject construct?

I ask this because I´m not able to trap events.

thank you
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top