Selenium Forum: Functional And Regression Testing Tool.
Would you like to react to this message? Create an account in a few clicks or log in to continue.
Search
Display results as :
Advanced Search
Latest topics
AEM Training | Free Online DemoWed Apr 21, 2021 5:45 pmazharuddin
c# PageFactory - issue initializing elementsFri Nov 01, 2019 8:40 pmthegoatboy
Selenium making automatic connection to random urlsMon Jul 08, 2019 12:58 pmrepairtechsolutions1
How can we design the custom framework in Selenium RCMon Jun 24, 2019 2:26 pmrandybonnettes
What are the new features in Selenium 3.0Tue Jun 18, 2019 5:37 pmpappyvicky
What are you using Selenium for? Fri Apr 12, 2019 3:52 amzhl
LIMITATIONS OF SELENIUMWed Apr 10, 2019 11:23 amswara
Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

Go down
avatar
Bhuvaneswari
Regular Participant
Regular Participant
Posts : 30
Join date : 2011-09-30
Location : India

Clicking a link not working Empty Clicking a link not working

Tue Jan 03, 2012 6:33 pm
After mouse over, a drop down appears with few menu links. Upon trying to click the link, failing. Please help me.

Code goes here,

selenium.mouseOver("id=NavigationMenuItem_6");
selenium.waitForPageToLoad("20000");
selenium.click("link=MenuItem_1"); //This line not working
selenium.waitForPageToLoad("60000");

Times out after 20 seconds. Could some one throw some light please.
avatar
faramka
Professional
Professional
Posts : 143
Join date : 2011-09-15
Location : Poland

Clicking a link not working Empty Re: Clicking a link not working

Tue Jan 03, 2012 7:06 pm
Before this line of code which is not working try check if the link really exists.
To do this, you can use an assertion or isElementPresent() command included in if statement.
avatar
Bhuvaneswari
Regular Participant
Regular Participant
Posts : 30
Join date : 2011-09-30
Location : India

Clicking a link not working Empty Re: Clicking a link not working

Wed Jan 04, 2012 12:59 pm
one mistake. Gave the Javascript id("link=MenuItem_1") for the link instead of the text("Menu") given for the link. After changing this it worked. Thanks for your reply any how.

Now I have another issue.

On clicking a icon, a new window(XWT) opens and I am not able to execute the commands on the new window. It fails. The script works till it opens the new window. If trying to type something, or click on any link on the new window, not working. Please help.
avatar
faramka
Professional
Professional
Posts : 143
Join date : 2011-09-15
Location : Poland

Clicking a link not working Empty Re: Clicking a link not working

Wed Jan 04, 2012 2:22 pm
Have you tried choose active window? Use selectWindow(id) and the id you can get by choosing one of the results of getAllWindowIds().


Last edited by faramka on Wed Jan 04, 2012 3:49 pm; edited 1 time in total (Reason for editing : mistake in method name)
avatar
Bhuvaneswari
Regular Participant
Regular Participant
Posts : 30
Join date : 2011-09-30
Location : India

Clicking a link not working Empty Re: Clicking a link not working

Wed Jan 04, 2012 3:41 pm
Thanks.

I tried like below,

After opening the new windows, inserted a line for 'getAllWindowIds()'. The array resulted 'undefined' for both new windows. Any thoughts please pale .
avatar
faramka
Professional
Professional
Posts : 143
Join date : 2011-09-15
Location : Poland

Clicking a link not working Empty Re: Clicking a link not working

Wed Jan 04, 2012 3:50 pm
Read THIS, maybe it could help.
avatar
Bhuvaneswari
Regular Participant
Regular Participant
Posts : 30
Join date : 2011-09-30
Location : India

Clicking a link not working Empty Re: Clicking a link not working

Wed Jan 04, 2012 3:52 pm
Sorry. You could have forgotten to paste the link/content.
avatar
faramka
Professional
Professional
Posts : 143
Join date : 2011-09-15
Location : Poland

Clicking a link not working Empty Re: Clicking a link not working

Wed Jan 04, 2012 4:32 pm
There is a link under word 'THIS'. You can click at it when you are logged in, can't you?
avatar
Bhuvaneswari
Regular Participant
Regular Participant
Posts : 30
Join date : 2011-09-30
Location : India

Clicking a link not working Empty Re: Clicking a link not working

Wed Jan 04, 2012 5:35 pm
Yeah, now I could open the link. But the selectWindow(WindowID) [selectWindow(name=windowID) or selectWindow(windowID)] throws the Error: Window does not exist.
avatar
Bhuvaneswari
Regular Participant
Regular Participant
Posts : 30
Join date : 2011-09-30
Location : India

Clicking a link not working Empty Re: Clicking a link not working

Wed Jan 04, 2012 5:37 pm
The following defect has not been resolved it seems.
SEL-703

Also no workarounds I get. Would be great if I get this resolved.
avatar
Bhuvaneswari
Regular Participant
Regular Participant
Posts : 30
Join date : 2011-09-30
Location : India

Clicking a link not working Empty Re: Clicking a link not working

Thu Jan 05, 2012 4:26 pm
Selenium IDE also fails to record the script for the actions performed on the new window. Any idea please.
Sponsored content

Clicking a link not working Empty Re: Clicking a link not working

Back to top
Permissions in this forum:
You cannot reply to topics in this forum