Subscribe Us

How To Click On Browser Forward Button in selenium Webdriver

.
Question : How To Click On Browser Forward Button in selenium Webdriver Using Java ?

Answer 
By using forward() method we click on browser forward button in selenium webdriver .

forword()
forward() is a navigation command in selenium webdriver used to click on browser froward button .

Syntax
forward();

Example 
driver.navigate().forward();

Selenium Code to click on browser forward button using java.


package automation;
import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.chrome.ChromeDriver;

public class ForwardMethod 
{
public static void main(String[] args)
{
System.setProperty("webdriver.chrome.driver", "C:\\Software\\chromedriver.exe");
WebDriver driver=new ChromeDriver();
driver.manage().window().maximize();
driver.get("https://www.facebook.com/");
driver.navigate().forward();
}
}

In this tutorial we learn how to click Browser forward button in selenium webdriver .Hope this tutorial helpful for you 😊

Thanks & Regards 
Sandeep Yadav

Important Tags
How to click on forward button in selenium , how to click on browser forward button , how to click on browser forward button in selenium using java.


How To Click On Browser Forward Button in selenium Webdriver



Post a Comment

0 Comments