Hello,
I am getting stuck while trying to get handle a Download Dialog in IE 8.
My scenario is:
. Lauching a web app1.
. From that, clicking on an Anchor, it will launch another browser with a Download Dialog displayed there.
I found out that most the examples and cases around this forum just mentions the Anchor to fire the Download Dialog inside the web app1 only, but my case is pretty difficult since it was automatically launched from another browser (I had 2 browsers after clicking on the Anchor on the web app1)
Does anyone have any idea to help me out?
Regards,
San
What I've tried:
I am getting stuck while trying to get handle a Download Dialog in IE 8.
My scenario is:
. Lauching a web app1.
. From that, clicking on an Anchor, it will launch another browser with a Download Dialog displayed there.
I found out that most the examples and cases around this forum just mentions the Anchor to fire the Download Dialog inside the web app1 only, but my case is pretty difficult since it was automatically launched from another browser (I had 2 browsers after clicking on the Anchor on the web app1)
Does anyone have any idea to help me out?
Regards,
San
What I've tried:
try
{
Utilities.GlobalObject.BROWSER = Utilities.GlobalObject.MANAGER.ActiveBrowser;
HtmlAnchor cphPageContent_btnExport = Utilities.GlobalObject.BROWSER.Find.ByAttributes<HtmlAnchor>(
"href=trend_charts.aspx?output=xls"
);
cphPageContent_btnExport.Click();
Utilities.GlobalObject.BROWSER.WaitUntilReady();
Utilities.GlobalObject.BROWSER = Utilities.GlobalObject.MANAGER.ActiveBrowser;
DownloadDialogsHandler handler =
new
DownloadDialogsHandler(Utilities.GlobalObject.BROWSER, DialogButton.SAVE, saveLocation, Utilities.GlobalObject.MANAGER.Desktop);
handler.WaitUntilHandled(20000);
}
catch
(Exception EX)
{
string
strE = EX.ToString();
Utilities.GlobalObject.LOGGER.log(strE);
}