Handling popup windows in selenium without window id

681 views
Skip to first unread message

saikrishna

unread,
Jan 11, 2011, 12:57:10 AM1/11/11
to Selenium Users
Hello All

i have a senario to automate, where my popup window does not contain
window id , title, name and any other element locator , is there any
workaround to automate such senario, please put your views



Thanks
Saikrishna

Binken

unread,
Jan 11, 2011, 1:12:25 AM1/11/11
to seleniu...@googlegroups.com
you can try selectWindow("title='sdfdf'")

deter

unread,
Jan 11, 2011, 1:13:36 AM1/11/11
to seleniu...@googlegroups.com
Did u try recording with Selenium IDE..It should identify the id of the pop-up window..

farheen khan

unread,
Jan 11, 2011, 1:21:16 AM1/11/11
to seleniu...@googlegroups.com
Hi,

Use windowfocus and selectwindow command to automate the scenario

On Tue, Jan 11, 2011 at 11:43 AM, deter <aler...@gmail.com> wrote:
Did u try recording with Selenium IDE..It should identify the id of the pop-up window..

--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To post to this group, send email to seleniu...@googlegroups.com.
To unsubscribe from this group, send email to selenium-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/selenium-users?hl=en.



--

Farheen
http://seleniumready.blogspot.com/



farheen khan

unread,
Jan 11, 2011, 1:35:47 AM1/11/11
to seleniu...@googlegroups.com
WaitforPopup("SampleWindowID", TIMEOUT");
SelectWindow("SampleWindowID")
WindowFocus() //// To give focus to the currently selected window.

BillR

unread,
Jan 11, 2011, 1:22:32 PM1/11/11
to Selenium Users
One thing you could try on Selenium 2 just to explore is:

for (String handle : driver.getWindowHandles()) {
System.out.println("win " + handle);
driver.switchTo().window(handle);
page = selenium_.getLocation();
System.out.println("href: " + page);
}


Not sure if this would catch popups, but it picked up a new window
that Selenium 1/RC didn't detect.
Reply all
Reply to author
Forward
0 new messages