Pop up html page

me_king

New Member
Joined
May 17, 2012
Messages
4
Hello everyone,
I am working on a website automation and I'm facing a real problem there. The web-site is Consumer Prices (MEI) : Consumer prices - Annual inflation and I am able to navigate the page. There is a drop down which has options of downloading the data from the site in various formats. There when you select an option a modal dialog pops up where in we have to click "Export to Excel". The problem I am facing is I cannot access the DOM object of the pop window. I have tried various methods like
Code:
[I]Public[/I] WithEvents [I]IE1 As InternetExplorer 
Public[/I] IE2 As [I]InternetExplorer[/I]

also I have tried the api to get the hold of the pop window but failed.
 

Excel Facts

Format cells as time
Select range and press Ctrl+Shift+2 to format cells as time. (Shift 2 is the @ sign).
Hello everyone,
I am working on a website automation and I'm facing a real problem there. The web-site is Consumer Prices (MEI) : Consumer prices - Annual inflation and I am able to navigate the page. There is a drop down which has options of downloading the data from the site in various formats. There when you select an option a modal dialog pops up where in we have to click "Export to Excel". The problem I am facing is I cannot access the DOM object of the pop window. I have tried various methods like
Code:
[I]Public[/I] WithEvents [I]IE1 As InternetExplorer 
Public[/I] IE2 As [I]InternetExplorer[/I]

also I have tried the api to get the hold of the pop window but failed.

Got the solution finally. Thank you
Code:
<code>
Set myhtmlframe = ie1.document.frames(1).document myhtmlframe.getElementById("btnExportToExcel").Click</code>
I was trying to load frames DOM before the new frame loads and so I thought it was not a frame but a modal window.
 
Upvote 0

Forum statistics

Threads
1,215,053
Messages
6,122,882
Members
449,097
Latest member
dbomb1414

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top