Selenium with C#

0 votes

I want to use Selenium WebDriver with C#. I have downloaded C# client drivers and the IDE. I added all relevant DLLs (Firefox) to the project, but I don't have Selenium Class. Kindly give me an example to do this.

May 31, 2018 in Selenium by Atul
• 10,240 points
267 views

1 answer to this question.

0 votes

using OpenQA.Selenium.Firefox;
using OpenQA.Selenium;

class Demo
{
    static void Main(string[] args)
    {
        WebDriver driver = new FirefoxDriver();
        driver.Navigate().GoToUrl("http://www.google.com/");
        WebElement find = driver.FindElement(By.Name("xyz")).SendKeys("hello");
        System.Console.WriteLine("Page title: " + driver.Title);
        driver.Quit();
    }
}
answered May 31, 2018 by Meci Matt
• 9,420 points

Related Questions In Selenium

0 votes
1 answer

How to open a browser window in full screen using Selenium WebDriver with C#

Simply Use this: driver.Manage().Window.Maximize(); READ MORE

answered Jun 7, 2018 in Selenium by Samarpit
• 5,130 points
4,242 views
0 votes
1 answer

Help me with the steps to write first Selenium C# test case.

Hey Wareena, you can use following steps ...READ MORE

answered Jun 10 in Selenium by Anvi
• 13,960 points
90 views
0 votes
2 answers
0 votes
1 answer

Finding WebDriver element with Class Name in java

The better way to handle this element ...READ MORE

answered Apr 10, 2018 in Selenium by nsv999
• 5,110 points
993 views
0 votes
1 answer
0 votes
1 answer

Geo-location microphone camera pop up

To Allow or Block the notification, access using Selenium and you have to ...READ MORE

answered May 11, 2018 in Selenium by Samarpit
• 5,130 points
1,144 views
0 votes
1 answer

How to use such xpath to find web elements

It's much simpler to use: #MyDiv123 > div.super or ...READ MORE

answered Jun 14, 2018 in Selenium by Samarpit
• 5,130 points
888 views
0 votes
1 answer

XPath for the elements with no ID or Name in Selenium Webdriver

Use like this or similar to this: //div[@id="top-level-menu-item-3"]/div[@class="filter-label"] //div[@id="top-level-menu1"] ...READ MORE

answered Apr 17, 2018 in Selenium by Meci Matt
• 9,420 points
1,472 views
0 votes
1 answer

Binding Selenium Javadoc with eclipse

First, you need to go to:- project properties ...READ MORE

answered Apr 17, 2018 in Selenium by Meci Matt
• 9,420 points
127 views