Welcome to the Question and Answer site for Software Testing Professionals

You can get your queries resolved from Software Testing Professionals.

Ask a Question

Get answers and give answers to questions from other members.

View All Questions

Get votes and earn points to build your reputation in community.

View Hot Questions

0
how to right click on Selenium WebDriver?

Open 2 Answers 37 Views
0 2
I am working on a scenario where I have to right click on the webpage and perform the operation. How do I do that using Selenium?

2 Answers

1
1
You can use below code to right click in Seleium Webdriver:

Actions action = new Actions(driver);
WebElement element = driver.findElement(By.id("elementId"));
action.contextClick(element).perform();
answered Dec 26, 2017 by sumitkumarwatts (530 points)
edited Dec 26, 2017 by mayur
0
0
You can use contextClick from actions classes.

Actions action= new Actions(driver);
action.contextClick(productLink).build().perform();

Hope that helps!
answered Dec 11, 2017 by mayur (733 points)

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:
To avoid this verification in future, please log in or register.

We have resolved 1.2k+ Software Testing queries!

Software Testing Board Weekly update

We will send you handpicked questions that you would love to answer.

View previous campaigns.

Top Contributors

...