Search
 
 

Display results as :
 


Rechercher Advanced Search

Latest topics
» how to connect DB in selenium webriver
Fri Oct 06, 2017 4:09 pm by anbarasi

» How find any text in browser screen and click on it?
Thu Oct 05, 2017 2:02 pm by sandeepkommineni

» Selenium Webdriver
Tue Oct 03, 2017 1:35 pm by PiyushBiswas

» GRID setup tutorial.
Wed Sep 27, 2017 4:29 pm by johnyapp

» Drag & Drop Between Windows Using Selenium Driver
Wed Sep 27, 2017 2:10 pm by 26rondel

» Check if window is closed / verify input
Sat Sep 23, 2017 10:21 pm by brainstir

» How to work on pages with AJAX in selenium?
Mon Sep 18, 2017 6:08 pm by azharuddin

» pause test until user press a key like F2
Wed Aug 09, 2017 11:10 pm by djnforce

» Selecting the input for auto populating element
Sat Jul 29, 2017 7:53 pm by kdabbara

Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

Unable to click menu with Link attribute

View previous topic View next topic Go down

Unable to click menu with Link attribute

Post by cerberus on Tue Aug 18, 2015 6:14 pm

Hi,

I am new to Selenium webdriver. My website has a Menu button with sub menus. The sub menu buttons can be accessed by either hovering over the Menu button or by clicking it. I have tried every combination but haven't been successful as of now.The source code is:

Code:
div class="divAPOAppMenu">
<ul id="projectDashboardMenu" class="sf-menu sf-js-enabled sf-arrows">
   <li>
   <li class="">
   <a class="sf-with-ul" href="#">Manage Assessment</a>
   <ul style="display: none;">
   <li>
       <a id="btnAddAssessment">
       <img style="height: 20px; width: 20px; float: left; margin-right: 5px; border: none;" src="../../Images/AddIcons.png" alt="">
       New Assessment
       </a>
       </li>


I am trying to click the sub menu with the text "New Assessment" using the.  :
Code:
Actions action=new Actions(driver);
WebElement moveToManageAssessmnt = driver.findElement(By.linkText("Manage Assessment"));
action.moveToElement(moveToManageAssessmnt).moveToElement(driver.findElement(By.linkText("New Assessment"))).click().perform();

This is throwing error.Can someone please suggest me how to click the sub menu button?? Any sort of help will be highly appreciated!! Thanks in advance !!!

cerberus

Posts : 1
Join date : 2015-06-24

Back to top Go down

Re: Unable to click menu with Link attribute

Post by AgoBalan on Thu Aug 20, 2015 6:04 pm

what error it throws..? in which step.. plz be specifc

AgoBalan
Amateur
Amateur

Posts : 36
Join date : 2015-02-23

Back to top Go down

Re: Unable to click menu with Link attribute

Post by anemuday on Sat Aug 29, 2015 2:49 pm

Please watch this video for clear demonstration of how to mouse hover on a webelement.


anemuday
Active particpant
Active particpant

Posts : 11
Join date : 2012-10-11

Back to top Go down

Re: Unable to click menu with Link attribute

Post by Sponsored content


Sponsored content


Back to top Go down

View previous topic View next topic Back to top


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