If you are searching for Selenium Webdriver tutorial then your search ends here. You can find the number of different topics which you will find in your day to day activity while doing automation. Selenium Webdriver is one of trending topic nowadays for Automation field and it is a highest paying job as well.

To learn Selenium Webdriver you should have at least one programming language. Currently, Selenium Webdriver is most popular with Java and C# so if you know any of the languages then it won’t be tough.

I have published some of the Java Videos on YouTube which will give you a quick start to learning Selenium Webdriver. Once you are done with Basic Selenium Webdriver then you can switch to Advance Selenium Tutorial with advanced Java topics.

Must read article before going Selenium Webdriver Tutorial

List of java topic for Selenium

 Best way to learn any automation tool 

Pain of an Automation Engg and Best practices to avoid

 Difference between Webdriver, RC and IDE

Top 100 Selenium Interview questions

Module 1-Selenium Webdriver tutorial

Setup the Environment- Setup Java, Eclipse, Selenium, TestNG

Download and Install Java

Configure Setup-Eclipse,Selenium,TestNG

Eclipse Tips and  Tricks

 

Module 2-Selenium Webdriver tutorial

Execute testcases in firefox browser using Selenium Webdriver

New- Start Firefox in Selenium 3 using Gecko driver

Start Firefox Browser in MAC Machine using Selenium Webdriver

Guide to execute testcases in Chrome browser using Selenium Webdriver

Start Chrome Browser in MAC machine using Selenium Webdriver

Remove or Disable Developer add-on in Chrome while running Selenium Test (New)

Hide or Block pop-up notification in Chrome browser during Selenium Test Execution (New)

How to execute testcases in IE browser using Selenium Webdriver

Execute your Selenium Webdriver Test on Microsoft Edge Browser

Challenges with IE browser in Selenium Webdriver

XPath plugin for Firefox 

Complete stydy of Dynamic XPath in Selenium

Write your own CSS in selenium to make script faster 

XPath plugin for Chrome

How to verify Page title in Selenium Webdriver

How to work with Radio button and Checkbox in Selenium Webdriver

Handle Basic Dropdown in Selenium WebDriver

Handle BootStrap Dropdown in Selenium WebDriver

How to work with file uploader or How to upload file in Selenium (using Robot class)

How to work with file uploader or How to upload file in Selenium (using AutoIT)

How to upload multiple files in Selenium using AutoIT

Guide to perform Drag and Drop in Selenium

How to perform Advance activity in Selenium like- Mouse Hover, RightClick, DoubleClick, Keyboard Event

Implicit wait in selenium Webdriver

Explicit Wait in Selenium Webdriver

Fluent Wait in Selenium Webdriver

Create custom library to solve sync issues in Selenium Webdriver

 

Selenium Webdriver tutorial

 

Module 3-Selenium Webdriver tutorial

How to capture error message in Selenium Webdriver.

How to Handle Multiple Windows in Selenium Webdriver

How to handle frames in Selenium Webdriver

How to handle Alert in Selenium Webdriver

Handle BootStrap Model Dialog in Selenium WebDriver

How to handle Calender in Selenium Webdriver

How to capture Screenshot in Selenium

Capture screenshots in Selenium using Robot class

How to capture screenshots of failed test cases in Selenium Webdriver

How to use Robot class in Selenium

How to generate log file in Selenium Webdriver using Log4j

What is Webdriver Listener and How to implement Listener in Selenium Webdriver

How to capture tooltip in Selenium Webdriver

How to handle Proxy in Selenium Webdriver

Simple steps to start default Selenium session in Firefox

How to Handle Untrusted Certificate in Selenium or How to handle SSL Certificate in Selenium

How to scroll page in Selenium Webdriver

How to scroll into view in Selenium or Handle particular scroll bar in Selenium

How to get Current System date and time in Selenium

How to run failed test cases automatically in Selenium

Handle Hidden WebElements in Selenium Webdriver  (Video)

 

Module 4- Selenium Webdriver tutorial

How to Execute Selenium test from command prompt

How to download files in Selenium Webdriver.

How to highlight Element in Selenium or Selenium Element highlighter

How to solve Maven issue in Selenium

How to handle Exception in Webdriver

Solution for java.lang.illegalstateexception in Selenium Webdriver

How to handle Element not visible exception

How to Handle Element is not Clickable in x,y coordinate 

Solution for sendkeys(CharSequence) in Selenium

How to Handle Stale element reference exception in Selenium Webdriver

How to handle JQuery in not a function exception

Guide to solve Invalid State Elememt Exception in Selenium

How to perform Flash testing in Selenium using youtube API

Javascript with Webdriver 

Difference between findElement and findElements in Selenium Webdriver

How to find broken links in Selenium Webdriver

=================================================

Web Services Testing

 

=================================================

Selenium Webdriver Tutorial for Beginners

Program to count number of occurrences of word in a string

 

317 thoughts on “Selenium Webdriver tutorial for beginners

  1. Nikhil devakar says:

    Hi mukesh
    Can you please make a vedio how to integrate google sheets with selenium(sheets instead of the excel).
    Waiting for the reply and vedio.

    Thanks in advance.

    1. Hi Nikhil, Selenium can only handle web automation so if we need to read or write data from google sheet then we need to use google sheet API for the same. I will try to record video on this soon.

      1. Akhila says:

        Hi Mukesh,

        As part of curriculum, do you also include any desktop automation tool basics and show the integration of both (desktop ans web) in Jenkins?

        Thanks

        1. Hi Akhila, This course does not cover desktop automation.

  2. Apu says:

    Hi Mukesh

    Thanks for all your videos. Is there any way we can validate the content of the XML and check if the correct data is present?

    1. Hi Apu,

      For this you may need to use XML parser using which you can validate XML file data

  3. RANJAN V says:

    Hi Mukesh,

    Your videos are very Nice 🙂

  4. Geetha says:

    Hi Mukesh,

    Your videos are excellent & very helpful. Thanks allot for creating such videos & sharing.

  5. Sridhar NM says:

    Could you please add “Handling Single sign on (SSO) in selenium JAVA

    1. Hi Sridhar,

      Using AutoIT or Robot class, you can achieve it but it is just a workaround

      1. Sai Krishna says:

        Hai Mukesh your videos were so helpful to learn testing…..and i am getting an exception as Element is not interactable . Please help me to solve such exception

        1. Hi Sai,

          Could you please try with JavaScript Link https://vistasadprojects.com/mukeshotwani-blogs-v2/click-in-selenium-webdriver-using-java-script/ and let me know about observations

  6. keshav says:

    Hi Mukesh,
    My Result for the url is like below

    {“status”:{“code”:1000,”message”:”SUCCESS”,”timestamp”:1575530291156},”response”:{“OTPValue”:798998}}

    I have to capture the otp value and I should pass it .
    I am unable to do this .
    Thanks in Advance.

    1. Hi Keshav,

      You need to parse above JSON using any json based library. Please refer this link https://github.com/fangyidong/json-simple

  7. Ankur says:

    Hi Mukesh,

    can your please share the list of java basic interview question so that it will help us cracking the selenium interview??

    Thanks

  8. pinki says:

    Hi Mukesh,

    Please help me to learn TestNG and Data Driven Framework.

  9. subha says:

    I want script for ide but i got question like without recording and playback i want to write the script .
    If anyone know this answer plz send to me

    1. Hi Subha,

      Use Selenium Webdriver which is more advanced than Selenium IDE.

  10. Vijay Kumar says:

    Hi Mukesh, I would like to know where can I get your full video lessons for selenium web driver application. I saw some of your videos in YouTube, but it missing continuity. Your response will be greatly appreciated. Thanks

  11. Shubham says:

    hi mukesh,
    I had studied most of advance topics from your site and they are most helpful

    1. Hi Shubham,

      Thanks for your appreciation…:)

  12. Soniya says:

    Hi Mukesh,
    Your Site and videos are very helpful.
    Thanks a lot!!!

    1. Hi Soniya,

      Thanks for your appreciation. You are always welcome to my blog. Please feel free ask your automation related doubts…:)

  13. Amit Sehgal says:

    Hello Mukesh, Do you have tutorials for JMeter

    1. Hi Amit,

      Apologies….as of now, I don’t have tutorials for JMeter.

  14. shiva says:

    Hi mukesh,

    do we have any solution to run selenium test cases in parallel?

    1. Hi Shiva,

      You can use TestNG to achieve your goal.

  15. kumar says:

    hi mukesh,

    how to download git. Could you please explain briefly.

    Thanks,
    Sandy

    1. Hi Kumar,

      Install git on your local machine. Then type git in cmd to check whether it is displaying help commands. Now use got clone

  16. Shiva says:

    Hi Mukesh,

    I am following your selenium videos since long back…. but now i see videos are not in seq or step by step, which is creating so confusion… could you please arrange them in seq so that it it will be helpful for the beginners.

  17. Priya says:

    hello Sir,
    Can you please tell me how to download microsoftwebdriver for windows 8

  18. Anbarasu says:

    Hi Mukesh,

    could you please share the video how to automate PDF validation through Selenium WebDriver

    1. Hi Anbarasu,

      As of now, I don’t have such video but you can refer this link https://pdfbox.apache.org/

  19. Darshan says:

    Hi Mukesh,

    Is it possible to automate sign in test case which has two step verification where we need to enter code from our registered mail ID? Is it possible to skip this test case in selenium? Or any way we can automate this??

    1. Hi Darshan,

      Selenium purely works on UI. Your query is related to authentication which differs application to application. If there are any APIs available for skip authentication then obviously you can integrate in to same framework.

  20. Rohit says:

    Can you tell me how to load test cases in ALM using selenium?

    1. Hi Rohit,

      Apologies…I Never worked on ALM…:(

  21. arjun says:

    Hello

    can u please upload the video for broken images part.
    its not there.

    thanks much!
    arjun

    1. Hi Arjun,

      I’ll upload it…:)

  22. jyoti says:

    Explanation is really good. Thank you for providing online study material.

    1. Hi Jyoti,

      Your appreciation made my day…:)
      Keep learning and visiting my blog.

  23. Dheeraj Pratap Singh says:

    Hi Mukesh,
    Current m using firefox version 59 and i am not able to add firebug on it so can you please help me in these. I did try many thing but didn’t succeed. Please help.

    1. Hi Dheeraj,

      Firebug supports till Firefox version 53. So if you want to use firebug then kindly downgrade firefox.

  24. Kannan says:

    Hi Mukesh, This link seems empty
    https://vistasadprojects.com/mukeshotwani-blogs-v2/tag/verify-page-title-in-selenium/ . Please make it available.

    Your posts was awesome. It was easy to understand. Thanks!

    1. Hi Kannan,

      Thanks for bringing this concern to me. Somehow few of my blog posts got deleted recently while maintenance. But you can visit my youtube video over here https://www.youtube.com/watch?v=DovuIQ8RojA
      I’ll post content the content…:)

  25. priyanka pandey says:

    https://vistasadprojects.com/mukeshotwani-blogs-v2/how-to-create-log-files-in-selenium/

    In this you have shared can save logs in html file
    is it possible to save in xls format.

    1. Hi Priyanka,

      Log4j is not able to interact with Excel file. In order to log in excel file, you can use Apache POI apis’. For more details, please visit this link https://vistasadprojects.com/mukeshotwani-blogs-v2/read-and-write-excel-files-in-selenium/

      1. Priyanka Pandey says:

        Hi mukesh thanks for reply.

        https://vistasadprojects.com/mukeshotwani-blogs-v2/how-to-capture-screenshot-in-selenium-webdriver/

        this tutorial video you have mention,adding screenshot in report.please the link.

  26. Aayushi says:

    Hello Sir,
    I have write the codr from login window to save form, when i click on save it come to the grid page, after that i click on other its not getting clicking and also not showing any error, i also tried switching window but nothing works. There is no error so i am not getting any to solve it

    1. Hi Aayushi,

      Did you check the possibility of any frame?

  27. Swapnal Gadekar says:

    Hi Mukesh,
    I have seen your U-tube video for ‘First Testcase in Selenium’ which is very useful for beginners like me.As we can practice simultaneously with scripting.thanks and really appreciated.
    Can you please send me link of other similar videos on selenium which are in sequence?

  28. mani says:

    Hi, Your tutorials are very useful. thanks and really appreciated. sent this comment by my first automation script 🙂

    1. Hi Mani,

      Very very thanks for your comments. Keep learning…:)

  29. Mohammed says:

    Hi Mukesh,

    Basically application is developed in .net (Visual Studio+C#). So can I use selenium with java to automation this application, If so, what kinda challenges i would face ? Pls Help me

    1. Hi Mohammed,

      For Selenium, only UI matters. Yes, you can use Java for Selenium.

  30. Ajay says:

    Hi Mukesh,
    Angular Js application Can be handled by Selenium Webdriver?

    1. Hi Ajay,

      If you are dealing Angular JS application then better to go for Protractor rather than bare Selenium.

  31. KavithaM says:

    Mukesh can u please tell me like how can i run the testng-failed.xml automatically for a testng class that has so many annotation like @test,@afterclass etc.Where should i run the TestNG runner in the Test class

    1. Hi KavithaM,

      Yes, you can run it using runner class.

  32. Sachin Patil says:

    Hi Mukesh,
    Can you please tell how stable is selenium with HTML 5, as I want to use it for my project.

    1. Hi Sachin,

      In HTML 5, few things won’t get automate by Selenium like tooltips on controls as these things are not available into DOM. So you need to accept few exceptions while automating HTML 5 application via Selenium.

  33. priyanka says:

    Hi Mukesh,

    I went through all you post and its really helpfull

    Could you please post one more post to integrate selenium with ALM and JIRA?

    This is one of interview question ask to me as well as now need to implement in project

    1. Hi Priyanka,

      In order to integrate selenium with ALM and JIRA we need some API which we dont have.

      Still I will try if I will find these API’s then I will let you know 🙂

  34. Sravanthi says:

    How to verify Page title in Selenium Webdriver

    This link is not working
    can you please check this

    1. Hi Sravanthi,

      Thanks for pointing out bugs on my blog. I ‘ll certainly look into this. But for time being, you can visit this stackoverflow link

  35. swetha says:

    hi mukesh,
    I am getting error like “missing artifact com.sun:tools:jar:0” in pom.xml after creating the maven project.
    While googling i got to know that it would be pointing to jre instead of jdk.
    But i checked it.. it is pointing to jdk itself
    could u pls give me the solution.

    1. Hi Swetha,

      Please send me pom.xml to mukeshotwani@learn-automation.com I will cross check.

  36. Hi Mukesh
    Please Solve the Problem,
    The method get(Class) is undefined for the type ExtentReports

    1. Hi Manish,

      If you are using ExtentReports Version 2.x.x then please refer this link https://vistasadprojects.com/mukeshotwani-blogs-v2/advance-selenium-reporting-with-screenshots-2/

  37. Harika says:

    Hi Mukesh,
    Your explanation is very nice and easy to understand. Can you please provide explanation on how to debug in eclipse with clear explanation.

    1. Hi Harika,

      I’ll post it soon…:)

  38. Priya says:

    Hello sir,
    What is org.openqa.selenium.ElementNotInteractableException: erroe an dhow to solve it

    1. Hi Priya,

      This exception occurs when element is available in DOM but not interactable to driver, like one element overlays another element. In order wait for element of your choice, you can put fluent wait with condition to check for clickability of element of your choice along with ignoring above mentioned exception class. For more info, please check this link https://vistasadprojects.com/mukeshotwani-blogs-v2/fluentwait-in-selenium-webdriver/

      1. Priya says:

        Thank in so much sir

  39. Aayushi says:

    hii,
    How to solve unable to locate element error

    1. Hi Aayushi,

      Check whether element is in frame or not. For more info, please check this link https://vistasadprojects.com/mukeshotwani-blogs-v2/handle-frames-in-selenium/

      1. Aayushi says:

        Thanx. its working now

  40. Robin Kondra says:

    Hi Mukesh,
    No matter what I try, I am unable to download TestNG. It show a list of errors.
    I tried downloading it from the Eclipse Marketplace, some offline down which are available were also tried. Please help me with some alternate solution.
    Thanks in advance!

    1. Hi Robin,

      Have you tried these ways being mentioned in link

  41. Prasanna Raj S says:

    Hi Mukesh,
    May I know what is the clear difference between Robot class and autoIT in uploading files or images in advanced selenium. Even i have to know how to download a image or file using the same and also with basic selenium coding

    1. Hi Prasanna,

      Robot class deals with keyboard events which works on all OS but Autoit which doesn’t deals with keyboard events works on windows OS only. AutoIT is best option on windows.

  42. Judy says:

    Hi Mukesh,

    Do you have any tutorial for the loop in Selenium? My scenario goes like this, I am creating different legal entity, once clicked CREATE, the next will also do the same and so on.

    1. Hi Judy,

      For this scenario, use dataProvider or loop it while reading from excel file using Apache POI

  43. Sunny says:

    I am getting Null pointer exception I did the same things as you did in the POM tutorial and I had mentioned webdriver driver in all the files as the same thing was asked by someone in the comment

    plz help

    1. Hi Sunny,

      NullPointerException is very generic exception which can occur by lot of ways and this is not a selenium specific issue. I would suggest you to debug your code to find where and which object value is becoming null.

  44. Shilpa says:

    Hello Mukesh,
    Requirement: I want to check a proper UI position of an element on page.
    So for this requirement I am fetching the (X,Y) coordinates of that specific element and then by assertEquals I am verifying that element is present on that position or not. Ex. Assert.assertEquals(683, HomePageHelpPoint.getX());

    Note: Also checking the Y coordinate also.

    Problem: The problem which I am facing is that if a single asset fails it stops the execution of test cse. So could you please provide me another solution like if assert fails then I can print a message and can continue with my execution.

    1. Hi Shilpa,

      Approach 1: You can use try catch block over here. Put your assertion in try block, error message in catch block. This will anyhow make your script execution as success
      Approach 2: Use soft assert, here script will get executed till end but script will flag failure finally.

      Now it is your choice to go with any approach.

  45. Ashutosh says:

    I have written the getWindowhandle() method to handle child window , but unable to move the control to child , any solution other than windowhandle method.

      1. D.K. Dewangan says:

        Hello Mukesh Sir,
        I have a scenario in automation. That is I have the list of accounts and each account has many projects, So when I go for automation testing, I just want to select an account which I want to check for. But I don’t want to change my code for testing each account. So what can I do?
        Help me,
        Thanks

        1. Hi Durgesh,

          You can use the concept of DataProvider. For more info, please go through this link https://vistasadprojects.com/mukeshotwani-blogs-v2/data-driven-framework-in-selenium-webdriver/

  46. Priya says:

    Hi Mukesh,

    Can you please help me in verifying that text or hyperlink is underlined or not.

    1. Hi Priya,

      Instead of checking for underline stuff, you can check its href attribute.

  47. Ramesh says:

    Hi Mukesh,
    Please let me know how to find a webElement (List Box) if all the recognition are same without using Xpath and CSS. If possible send the codes.

    Thank you.

    1. Hi Ramesh,

      So in your case, if I am correct, attribute of a property points to multiple nodes. Put all corresponding webelements into a list and iterate it using index.

  48. suneetha says:

    Hi Mukesh ,

    Thanks for reply.
    Can you please let me know if 2.53.1 compatible with FF 47.0.2 with out geckodriver
    Wanted to know if 3.5.3 is ready to use or not.

    1. Hi Suneeta,

      I am not sure about FF 47.0.2 with Selenium 2.53.1. Selenium 2 doesn’t require any gecko driver but Selenium 3 needs it. I would suggest you to use selenium 2.53.1 with FF 46.0. Chromedriver should be 2.32

  49. Nitesh says:

    hi
    i have one issue once i click on link one popup will open and oi need to handle that popup by selecting radio button once u select radio button it ll allow me to select dropdown and date how to handle this please help

    thanks
    Nayak

    1. Hi Nitesh,

      Check whether pop up is another window or iframe. If not then you can directly apply your required action on controls.
      Please go through these links 1 https://vistasadprojects.com/mukeshotwani-blogs-v2/handle-multiple-windows-in-selenium-webdriver/
      2. https://vistasadprojects.com/mukeshotwani-blogs-v2/handle-frames-in-selenium/

  50. suneetha says:

    Hi ,
    For selenium 2.48.2 which Firefox version supported.

    1. Hi Suneetha,

      2.48.2 is too old. Use 2.53.1 with FF 46.0. As selenium 3 is still not yet matured fully.

  51. swetha says:

    Hello sir,
    Your blog is so much useful .Its awsome.:)
    I am trying to run selenium code , getting this exception :org.openqa.selenium.firefox.NotConnectedException: Unable to connect to host 127.0.0.1 on port 7055 after 45000 ms. Firefox console output:

    Can you please tell me which version of firefox , chrome, IE supports Selenium 3.0 .

    Thanks in advance

    1. Hi Swetha,

      For Selenium 3, firefox and gecko driver should be latest. For chrome, chromedriver should also be latest. IEDriverServer according to Selenium version.

  52. Shilpa Mundra says:

    Hi Mukesh,

    Could you please provide an example for chrome browser with browserstack

    1. Hi Shilpa,

      Login to your BrowserStack account -> Click on Automate link on top menu -> The click on Resources drop down menu – > Select which language you want -> Then you can see code snippet to connect with BrowserStack

      1. Shilpa Mundra says:

        hi. I tried to automate it through Java but getting error like

        Exception in thread “main” org.openqa.selenium.remote.UnreachableBrowserException: Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure.
        Build info: version: ‘2.43.1’, revision: ‘5163bce’, time: ‘2014-09-10 16:27:33’
        System info: host: ‘SGPDWMVDI033599’, ip: ‘10.219.163.242’, os.name: ‘Windows 7’, os.arch: ‘x86’, os.version: ‘6.1’, java.version: ‘1.7.0_40’
        Driver info: driver.version: RemoteWebDriver

        Could you please tell me why I am getting this error?

        1. Hi Shilpa,

          Which selenium version are you using?

  53. Ajinkya says:

    Hi Mukesh,

    Thanks for such good tutorial.I just want to know the frequently asked programs in selenium with java interview .If possible please mention all program with code.

    Thanks

    1. Hi Ajinkya,

      I’ll update it with answers…:)

  54. chandrima says:

    hi Mukesh..
    I am some issues while executing the sceenshot command.below is the code.
    System.setProperty(“webdriver.chrome.driver”,”D:\\Selenium\\chromedriver.exe”);
    WebDriver driver = new ChromeDriver();
    driver.get(“http://google.com/”);

    File scrFile = ((TakesScreenshot)driver).getScreenshotAs(OutputType.FILE);
    // Now you can do whatever you need to do with it, for example copy somewhere
    try {
    FileUtils.copyFile(scrFile, new File(“c:\\tmp\\screenshot.png”));
    } catch (IOException e) {
    // TODO Auto-generated catch block
    e.printStackTrace();
    }

    and the error is:-
    Starting ChromeDriver 2.27.440174 (e97a722caafc2d3a8b807ee115bfb307f7d2cfd9) on port 21872
    Only local connections are allowed.
    Exception in thread “main” org.openqa.selenium.WebDriverException: unknown error: cannot get automation extension
    from unknown error: page could not be found: chrome-extension://aapnijgdinlhnhlmodcfapnahmbfebeb/_generated_background_page.html

    Please tell me where i am doing wrong.

    1. Hi Chandrima,

      Please Use chromedriver 2.31

  55. Priya says:

    Hi Mukesh,

    I have a general question.This is asked in one interview in System.setProperty(“webdriver.chrome.driver”,”fielpath.exe”)
    we have provided .exe, does this means selenium interacts with desktop based appins?

    Thanks in Adavance

    1. Hi Priya,

      This doesn’t mean that you are going to interact with desktop based applications in straight way but it is nothing more than setting an environment variable temporary so that it can call web browser instance which helps webdriver instance to interact. It is like setting java path in environment variables.

  56. Bhoomika says:

    Hello Sir,
    i am not from it background , right now i am working as a manual tester. i am learning automation from your video tutorial.
    it’s so much easy to understand thanks for this.
    but i have one question ,
    can you please tell me how to find Xpath without using firebug?
    how to write xpath with help of inspector ?

  57. bhavana singh says:

    Hi Mukesh,

    I don’t know how to thank you because your selenium video’s made my Selenium learning so easy. Thanks a ton. You are the best teacher and your knowledge on automation and generosity to share it is commendable. After this will definitely enroll for your framework course also. Keep up doing a good job.

    1. Hey Bhavana,

      Greeting of the Day !!

      Your most welcome and keep learning and thank a ton for such a nice feedback.

      Feel free to call for any query in framework course if any +91-8123547984

      Thanks
      Mukesh

  58. Uma mahesh says:

    Unique destination to Automation…???
    I’m very much impressed to your tutorials… simply pin point explaination.
    Can I get your tutorials PDF copy ?

    1. Hi Uma,

      Very very thanks for your appreciation.
      But sorry to say, I don’t keep pdf version of posts.

  59. mahendran says:

    Awesome blog!!!

    1. Hi Mahendran,

      Thanks for your comments…Be in touch…:)

  60. sonali says:

    hello sir,
    how to avoid “Do you want google chrome to save your password for this side” message.

  61. Amol Padwal says:

    Hi Mukesh,
    Thanks for all tutorial i am new in automation and relay all this tutorial are helpful for me. i would like to learn selenium from scratch so please guide me, how much java required for selenium and which java topic are impotent for selenium so i will concentrate on those topics first.

    1. Hi Amol,

      Java is like ocean, how much you dive that much you learn. And frankly there is no specific topics of Java which are being used for automation script. I would suggest you to learn Java first https://www.javatpoint.com/java-tutorial

  62. Rajini says:

    Hello Mukesh sir,
    Good evening ,
    i have knowledge on java , i would like to learn selenium from basic it self.
    i have seen ur videos but am getting confuse from where should i start could you please advise from which video i should start step by step procedure.

    thanks.
    Rajini

  63. Mohit says:

    how to handle radio buttons with same properties and even same name. and suppose i want to click one radio button

    1. Hi Mohit,

      Using common locator property, read all webelements into a list and iterate it to certain index which you want.

  64. Imran says:

    Hi Sir,
    Thanks for the materials which you have provided. I got lot of help from these resources of yours and have recommended this site to many of my friends.
    Actually i have a question for which i did n’t get correct/exact answer from anyone. Could you please help me out with this. here is my Query.
    -> We have developed our site using Angular js and we are facing issues with waits as none of the waits are working with our app except Thread.sleep but we have lot of dynamic content so it’s not advisable to use thread.sleep but we don’t have any other option. Could you please confirm if this is true that other wait functions will not work with Anjular js apps and is using Protractor the only solution to avoid wait issues or this can be handled by using some custom wait functions ?

    1. Hi Imran,

      Selenium itself is not able to handle angular js application that’s why Google brought Protractor into market. Protractor also gives you extra locators apart from 8 locators being provided by Selenium as Protractor is a wrapper over Selenium APIs. If your application is built on angular js than I would suggest you to go for Protractor for automating your application.

  65. Surbhi says:

    Hii
    Mukesh sir
    I m getting -FAILED: mouseHover
    org.openqa.selenium.NoSuchElementException: no such element: Unable to locate element: {“method”:”xpath”,”selector”:”.//*[@id=’ui-id-24′]/a”}
    For the below code, plz suggest me the mistake
    package Module2;

    import org.openqa.selenium.By;
    import org.openqa.selenium.WebDriver;
    import org.openqa.selenium.WebElement;
    import org.openqa.selenium.chrome.ChromeDriver;
    import org.openqa.selenium.interactions.Actions;
    import org.testng.annotations.Test;

    public class Mousehover_clickonWebelement {

    @Test
    public void mouseHover() throws InterruptedException{
    System.setProperty(“webdriver.chrome.driver”, “src\\chromedriver.exe”);
    WebDriver driver = new ChromeDriver();
    driver.get(“http://bestfoodplaces.com/”);
    driver.manage().window().maximize();
    Thread.sleep(5000);
    driver.findElement(By.id(“rest_name”)).sendKeys(“pla”);
    Thread.sleep(3000);
    WebElement ele= driver.findElement(By.xpath(“.//*[@id=’ui-id-24′]/a”));
    ele.click();
    Actions select = new Actions(driver);
    select.moveToElement(ele).build().perform();

    Thread.sleep(2000);
    select.click(ele).build().perform();
    }
    }

    1. Hi Surbhi,

      First you need to handle login window pop up and check with the xpaths being used in code.

  66. Ashwini says:

    Hi…
    I am trying using List for counting all links on webpage. But getting an error “Remove type argument”.
    Code written:
    List links= wd.findElement(By.tagName(“a”));

    1. Hi Ashwini,

      wd.findElement(Locator) returns a WebElement and wd.findElements(Locator) returns a list of WebElements.

  67. Hitendra says:

    Hi,
    Mukesh,

    as i have created xpath but in selenium it is not working and not select the value from the drop down.
    //div[contains(@id,ui-id-i)]/select

    1. Hi Hitendra,

      Just with some xpath, it is impossible to say about what kind of drop down you are dealing with. I would suggest you to go through below mentioned two links. First link works with select tag which you can observe in corresponding post.
      1. https://vistasadprojects.com/mukeshotwani-blogs-v2/handle-dropdown-in-selenium-webdriver/
      2. https://vistasadprojects.com/mukeshotwani-blogs-v2/handle-bootstrap-dropdown-in-selenium-webdriver/

  68. Kavya Bachimanchi says:

    Can u tell me how we can use this selenium on Mobile

  69. Amol Padwal says:

    Hi Mukesh,
    This for selenium tutorial, Its really helpfull for beignrrs as well as experienced person. Just i have a small request it difficult to find “Selenium Webdriver tutorial for beginners” page on a website. if you create tutorials tab then it good for easily navigate to the tutorial page.
    Thanks.

    1. HI Amol,

      Thanks for your constructive comment. I’ll surely do it in my blog…:)

  70. Deepika says:

    Hi Mukesh,
    In the dropdown i have few values like a,b,c and — and c,d,e.
    I want to select all the dropdwon values except –.How to do this. If i use getOption method it will display all options including –. If i use if condition like if text == — and put break it will come out of loop.it will not display rest of the options. Please suggest me on this.How i will do this?

    1. Hi Deepika,

      WebDriver will bring everything whatever locator property being provided. We need to handle by our login to remove unwanted data. In your case also, whenever you get all options of dropdown then we remove ‘-‘ from list. And wrt to break statement, please try to debug your code.

  71. Rakshith says:

    Hii Mukesh,

    how to identify the elements which id’s keeps on changing.

    Suppose id=ab_123 and 123 changes to 456 etc…

    how to identify such elements..please help me

    1. hi Rakshith,

      Try with dynamic xpath with keyword ‘starts-with’. For detailed information, please check this link https://vistasadprojects.com/mukeshotwani-blogs-v2/how-to-write-dynamic-xpath-in-selenium/

  72. prateek says:

    hi,
    i am using below code to take screenshot.

    package capturescreenshot;
    import java.io.File;

    import org.apache.commons.io.FileUtils;
    import org.junit.Test;
    import org.openqa.selenium.By;
    import org.openqa.selenium.OutputType;
    import org.openqa.selenium.TakesScreenshot;
    import org.openqa.selenium.WebDriver;
    import org.openqa.selenium.firefox.FirefoxDriver;

    public class CaptureSS {
    WebDriver driver;
    @Test
    public void captureS() throws Exception{
    System.setProperty(“webdriver.gecko.driver”,”C:\\Users\\prateek.sharma\\Downloads\\selenium\\geckodriver.exe”);
    driver=new FirefoxDriver();
    ………………..

    ===============================================
    Default test
    Tests run: 0, Failures: 0, Skips: 0
    ===============================================

    can you please advise what could we the issue??
    thanks

    1. Hi Prateek,

      Import testng.annotation library instead of junit.Test

  73. Roupya says:

    Hi Mukesh
    I am getting ” java.lang.NullPointerException”
    for the below code, please suggest what the mistake
    public class Capture
    {
    public WebDriver driver;
    public int i;
    public void takeSnap()
    {
    try {
    File srcFile = ((TakesScreenshot)driver).getScreenshotAs(OutputType.FILE);
    File destinationFle = new File(“./reporter/img.png”);
    FileUtils.copyFile(srcFile, destinationFle);
    }catch (IOException e) {
    System.out.println(“Some exception”);
    e.printStackTrace();
    }
    }
    @Test
    public void startExecution()
    {
    Capture c=new Capture();
    System.setProperty(“webdriver.chrome.driver”, “./drivers/chromedriver.exe”);
    driver = new ChromeDriver();
    driver.manage().timeouts().implicitlyWait(30, TimeUnit.SECONDS);
    driver.manage().window().maximize();
    driver.get(“https://vistasadprojects.com/mukeshotwani-blogs-v2”);
    System.out.println(driver.getTitle());
    c.takeSnap();
    driver.quit();
    }

    }

    1. Hi Roupya,

      While invocation of takeSnap() method, driver object becomes null. Two ways…Either pass driver object to this method or make driver object as static during its declaration.

  74. Harika says:

    Hi Mukesh,
    You are doing a greate job.

    This is my testng program, and when i try to run this program getting bellow error message.Please help me in running the testng program.
    Eclipse-3.8.3, java 8, testng jar files : testng-6.8.7.jar , testng-6.8.7-sources.jar

    package testng;
    import org.testng.annotations.*;

    public class TestngDemo {
    @Test
    public void test()
    {
    System.out.println(“Hello,this is sample testNG program”);
    }

    }

    Error: A JNI error has occurred, please check your installation and try again
    Exception in thread “main” java.lang.NoClassDefFoundError: com/beust/jcommander/ParameterException

    1. Hi Harika,

      I am not sure about Eclipse 3.8.3. It would be better if you use latest Eclipse along with testng jar of version 6.9.10(http://central.maven.org/maven2/org/testng/testng/6.9.10/testng-6.9.10.jar) and don’t use existing one

  75. Deepak Gupta says:

    How to handle sub child windows(more than 3) using Selenium Web Driver with Java

    1. Hi Deepak,

      In case of more than 2 windows, switch driver to each window bi iteration and verify title or any other specific property from window. If it matches the required window then stay on it otherwise do same on next window.

  76. Mit says:

    Superb blog !!!!

    Thank you very much Mukesh 🙂

    1. Hi Mit,

      Feeling pleased to read from you. Be in touch..:)

  77. Babu says:

    Hi Mukesh, Can u Show me how to Re Run the Failed TestCases at suit level for all the test cases? or Refer me any Reference

  78. mannu says:

    Hi Mukesh,

    How do I acess ur Blog??Need to know the concepts related to Xpath.Please help me with the link.

  79. Anil Ransing says:

    Hi Mukesh,

    I am a big fan of your Selenium WebDriver blog, reading and following you since 2 years.

    Currently I am trying to automate one of application which is build in Vaadin framework as a result I am having too many problems. The main issues are Vaadin application use only classes, there is no id, name or other elements, secondly, it has a syncing issue, I have tried all waits but it didn’t work reliably. there are other issues related to DOM as well.
    Kindly, if you know how to automate Vaadin application using selenium WebDriver (no testbench) then please post some articles on it.

    Thanks in advance.
    Anil

    1. Hi Anil,

      Sorry to say, but I never worked with Vaadin Framework.

    2. Ann says:

      Hi Anil,

      Where you able to automate your Vaadin application using Selenium? I’m truing to do the same with robot framework and I find some issues in between. Though I try to extract xpath, it doesn’t locate all the elements.

      Thanks,
      Ann

  80. sumit vani says:

    Hi, I am facing trouble to click on google map auto suggest location , I have select one suggestion.

    1. Hi Sumit,

      Please check whether you can see those suggestions in DOM structure too.

  81. Nikhil says:

    I am start to learning selenium from basic to advance & I want to become complete package for automation.
    what it the sequence of learning ?
    Request you to Kindly upload the video for practical example..
    Thank You..

    1. Hi Nikhil,

      I’ll do it soon…:)

  82. Dinesh Guptha Sivaguru says:

    Hi Mukesh,
    I could see only 10 videos in “Java Videos on YouTube “.Is this enough to start learning selenium with these 10 basic JAVA concept or will you post more video on JVA topics?

    1. Hi Dinesh,

      These videos are for basic learning but covering everything for Selenium and Java is very huge topic. But very soon I’ll post more videos on this topic.

      1. Dinesh Guptha Sivaguru says:

        ok Thanks for your reply:)

  83. Ashwary says:

    Unable to locate element:
    org.openqa.selenium.NoSuchElementException: Unable to locate element: {“method”:”xpath”,”selector”:”html/body/div[1]/div[2]/section/div[1]/div/div[2]/section[2]/div/form/div[42]/div/div[1]/textarea”}
    Command duration or timeout: 377 milliseconds

    why this problem always comes…..i m fed up by this…….i tried every thing mukesh…

    1. Hi Ashwary,

      Try with another locator method.

  84. Ash says:

    plz help ,close function is not working

    public class Urbille12sprint {

    WebDriver d;

    @Test(priority=1)
    private void closeBrowser() {
    d.close();
    }

    }

    1. Hi Ash,

      Call d.quit()

  85. Imroz Ansari says:

    Hi Sir I want know. why are my code is not run ,It want to run gmail properly login .I m using xpath plz check the error .My problem in enter the password using xpath
    public class LaunchGmail {
    public static void main(String[] args) {

    System.setProperty(“webdriver.gecko.driver”,”F:\\gecodriver\\geckodriver-v0.15.0-win32\\geckodriver.exe”);
    WebDriver driver = new FirefoxDriver();

    driver.navigate().to(“https://accounts.google.com/ServiceLogin#identifier”);
    driver.findElement(By.xpath(“//input[@id=’Email’]”)).sendKeys(“imran@finesofttechnologies.com”);
    driver.findElement(By.xpath(“//input[@id=’next’]”)).click();
    driver.manage().timeouts().implicitlyWait(10,TimeUnit.SECONDS) ;
    driver.findElement(By.name(“Passwd”)).sendKeys(“xyz”);
    //driver.findElement(By.xpath(“//input[@id=’signIn’]”)).click();
    }
    }

    1. Hi Imroz,

      Your code is working fine for me. The only difference is that I ran your code with Selenium 2.53.1 with FF 46.0.

      1. sunanda says:

        Hi mukesh
        Actually i am not getting how to take find element from this “onclick=”javascript:CallSaveUserDetails(‘2091′,’abcd’,’true’); return false;”

        Can u please help….

        1. Hi Sunanda,

          There should be a tag in which this statement resides. Try to use that tag for locator

  86. Koteswari says:

    hi, Mukesh,
    Could you post the steps to run selenium script over the VPN client.

    1. Hi Koteswari,

      VPNs’ are usually used in organizations. And I don’t have my own VPN connectivity. You can login to VPN machine, clone your scripts and run it from there. If you are running it from your machine it requires authentication recognition for security token and network proxy.

  87. deepak says:

    Hi mukesh, I trying with code that in case of fail it wirte in excel “Fail” but always it write pass. if title not match. please suggest.

    public String verify_Title(String object, String data)
    {
    APP_LOGS.debug(“calling copareTitle function”);

    String actual_title=driver.findElement(By.xpath(OR.getProperty(object))).getText();
    System.out.println(actual_title);
    String expected_Title=OR.getProperty(data);
    System.out.println(expected_Title);
    try{
    if(actual_title.equals(expected_Title)){
    System.out.println(“Title matched”);}

    }
    catch(Exception e){
    return “Fail”;
    }
    /* else{
    System.out.println(“Title not matched”);
    }*/
    return “PASS”;

    }

    1. Hi Deepak,
      There is small mistake in the login implemented over here. Here you are returning “PASS” at end of method which will always return “PASS” in any circumstances. Put this return statement inside try block.

  88. TuanNguyen says:

    Hi Mukesh Otwani, Lessons are very useful. Can you show me how to get elements that template bindings ? Thank in advance.

    1. Hi TuanNguyen,

      Could you please elaborate…

  89. Babu says:

    Hi Mukesh.. Thanks for Maintaining this Helpfull Blog. Coming to point.. can you share a concept to read Input data from XML file like data driven

  90. praveen says:

    Hi Mukesh,
    I want to capture Employers drop down (top right side of the page) and click on any one of the drop down values in monsterindia.com web page. But i am getting error. ( org.openqa.selenium.ElementNotVisibleException: Element is not currently visible and so may not be interacted). can you please help
    Below is the code:
    driver.get(“http://www.monsterindia.com/”);
    Actions builder=new Actions (driver);
    WebElement employee=driver.findElement(By.xpath(“.//*[@id=’empuser_wrap’]/div/div/a”));
    driver.manage().timeouts().implicitlyWait(15,TimeUnit.SECONDS);
    builder.moveToElement(employee);
    driver.findElement(By.xpath(“.//*[@id=’empuser_wrap’]/div/div/div[1]/ul/li[1]/a”)).click();

    1. Hi Praveen,

      Use it this way….
      driver.get(“http://www.monsterindia.com/”);
      Actions builder=new Actions (driver);
      WebElement employee=driver.findElement(By.xpath(“//*[@id=’empuser_wrap’]/div/div/a”));
      driver.manage().timeouts().implicitlyWait(15,TimeUnit.SECONDS);
      builder.moveToElement(employee).build().perform();
      driver.findElement(By.xpath(“//*[@id=’empuser_wrap’]/div/div/div[1]/ul/li[1]/a”)).click();

      FYI: Use Selenium 2.53.1 with FF 46 as Selenium 3.x.x has issues with Actions class

  91. Manjusha says:

    Hi mukhesh,
    when i was trying to inspect element browser should display html,css,script,DOM,Net,Cookies. But my browsers are displaying console,sources,network,timeline,profiles,Application etc. Do I need to change any settings here?

    1. Hi Manjusha,

      This is what web browser developer tool shows. I am also getting Elements, Console, Sources, Network, Timeline, Profiles, Application, Security, Audits tabs.

  92. Mahul says:

    Hello Mukesh,
    I am trying to launch the chrome driver using selenium webdriver but not able to launch. I am getting below error message:
    [4880:4732:0315/231144.005:ERROR:cache_util_win.cc(20)] Unable to move the cache: 5
    [4880:4732:0315/231144.005:ERROR:cache_util.cc(134)] Unable to move cache folder C:\Users\Mahul\AppData\Local\Google\Chrome\User Data\ShaderCache\GPUCache
    And my CODE is:
    import org.openqa.selenium.WebDriver;
    import org.openqa.selenium.chrome.ChromeDriver;

    public class Test1 {
    public static void main(String[] args) {
    System.setProperty(“webdriver.chrome.driver”,”C:/Program Files (x86)/Google/Chrome/Application/Chrome.exe”);
    WebDriver d = new ChromeDriver();
    d.get(“http://www.seleniumhq.org/download/”);
    d.quit();
    }
    }
    Please help me.

    1. Hi Mahul,

      If you are using Selenium webdriver then you need to provide chromedriver.exe path from you local machine not the chrome.exe path which comes when you install Google Chrome. You can download chromedriver.exe from thsi link http://chromedriver.storage.googleapis.com/2.28/chromedriver_win32.zip

  93. Anusha says:

    Hello Mukesh , I am learner of selenium web driver. I was trying to write a code in eclipse for a scenario, which i was unsuccessful.

    Scenario:
    ive an excel sheet with values as below :
    Y http://www.newtours.aut.com Welcome tours (page title)

    i wan to write a code if datatorun is equal to Y then navigate to the url in the sheet , verify the page title with the actual one and print the result as pass or fail in excel sheet.

    Can you help me with this

    1. Hi Anusha,

      Create a logic like one outer loop which will iterate excel sheet one by one. Column index is fixed for each stuffs. Here first check, either ‘Y’ or ‘N’, if ‘Y’ then read url from next next column and pass this url as argument to method which can call driver.get(“—–“) and this method should return page title. Now compare this actual title with data available inside excel on same row but different column. And if, first check is ‘N’ then iterate row count i.e. outer loop.

  94. Dinesh Guptha Sivaguru says:

    Hi Mukesh,

    When I tried the below steps with casting, I got negative value….could you please explain this concept

    byte by=(byte) 151;
    System.out.println(“the new byte value is”+by);

    The result is : -105

    1. Hi Dinesh,

      Please check this link

      1. Dinesh Guptha Sivaguru says:

        Sure will check….Thanks

        1. Hi Dinesh,

          Sure….

  95. Megha says:

    Can you give me a example how to use property file and how to use it in selenium web driver. How to use property file for showing result in website. In all examples they showed result running in command prompt

    1. Hi Megha,

      I hope this link will help you alot

  96. ram says:

    Hi, sir i have doubt how to use apachi poi for reading and writing data in excell sheet

  97. sonali says:

    hello sir,i want to ask you one question that if there are multiple ok buttons lets say 100 on webpage how will you click on second last ok button.

    1. Hi Sonali,

      If the buttons are also in same order in DOM as that of ui then find locator which can provide you all buttons. Put them in a list and iterate from backwards.

  98. Sravan says:

    Hi Mukesh,

    Please update the selenium webdriver videos in order

    1. Hi Sravan,

      Thanks for pointing this, even lot of my blog visitors are demanding same thing. I’ll do it soon.

  99. Amit says:

    Hello Mukesh.
    i am facing issues in running the selenium programs, FF is opening , but its throwing below error in console exiting the program. looks like some configuation issue.
    Firefox verison : 51 ( latest )
    selenium : 2.41
    i am trying to run the old script using the latest FF i am seeing this issue.

    org.openqa.selenium.firefox.NotConnectedException: Unable to connect to host 127.0.0.1 on port 7055 after 45000 ms.

    1. Hi Amit,

      Selenium 2.41 doesn’t support FF 51. Use selenium 3.1 with geckodriver for FF 51. For more details, please refer this link https://vistasadprojects.com/mukeshotwani-blogs-v2/use-firefox-selenium-using-geckodriver-selenium-3/

  100. Prasad says:

    Hi Mukesh Sir,
    How to run Selenium automation script in web server, since server not hosting any browser( I do have selenium script in local machine wanted to host this script in web server to run remotely)

    1. Hi Prasad,

      You can use Selenium Grid for this. Please have a look on this post https://vistasadprojects.com/mukeshotwani-blogs-v2/selenium-grid-for-remote-execution/

  101. Sorathiya Paresh says:

    Hi Mukesh ,

    Can we customise settings in chrome developer tool using capabilties for browser

  102. Megha says:

    Hi,
    You said Firefox is a default browser for Selenium IDE, but it does not support support for java 1.7 and selenium 2.53. Or does it support firefox. If so ? can you explain me how to do that.

    1. Hi Megha,

      Which version of FF are you using?

  103. Maheswaran says:

    How to handle http://only-testing-blog.blogspot.in/ in iframe i feel to difficult please help me.

  104. Garima says:

    Hi Sir,
    Is all these topic that have you mentioned for Basic and selenium webdriver Advance are enough to crack any interview.

    1. Hi Garima,

      In my opinion, these topics covers most of the portions but it all depends on interviewer knowledge also. Knowledge always comes when you involve yourself in real times automation of applications and how you are able to bring client/stakeholders requirements into your project. No doubt, these topics will help you alot for your interview preparations.

      Anyway, best of luck for your interview…:)

  105. Jyoti says:

    Hi Sir
    Can you suggest me some Link for learning about How Regression Testing can be done for a project with some practical examples

    1. Hi Jyoti,

      Regression test happens when tester get new application build with some code fix and some enhancements so that previously working functionality should work fine.

  106. Jyoti says:

    if we click on save button without entering any of the textbox filed and if that textbox field is mandatory then it asks for validation like Enter first name..for such kind of registration page how can we write test cases?

  107. Jyoti says:

    Hi Sir.
    Have You uploaded the video to Test a Simple Registration Page which includes First Name,Last Name,Mobile Number,Email-Id with its proper validations for a textbox fields using Selenium WebDriver…If Yes, Let me Know the URL or website of it..

    Thanks In Advance.

    1. Hi Jyoti,

      I didn’t post such video. But tell me, what do you mean by validations for these fields.

  108. Hi Snehal,

    You forget to set gecko driver path.

  109. Sorathiya Paresh says:

    hi Mukesh
    How can we automate opening the chrome developer tool.

    1. Hi Sorathiya,

      If you want to enable developer tool, then yes you can do it using keyboard events but automation of developer tool is not possible using Selenium APIs.

  110. Jyoti says:

    Hi Sir,
    Can you Please Post the video for How can we test a simple Registration page which includes First Name,Last Name,Mobile Number,Email-Id with its proper validations for a textbox fields…

    Your Previous replies Helped me alot..Thank you for that sir..

  111. Jyoti says:

    Can we write code to check whether the Right Click is disabled or not for the page using selenium webdriver?

    1. Hi Jyoti,

      Selenium library provides right click operation using Actions class (contextClick). After this operation, you can verify whether menus are displayed or not.

  112. Jyoti says:

    Hi Sir,
    how to check whether a textbox accepts special characters ot not using selenium webdriver..And how to check the validation for Mobile Number using Selenium webdriver..
    Please let me khow the answer for these two questions..
    Thanks in Advance

    1. Hi Jyoti,

      There is no answers for these two questions from Selenium APIs. Selenium can pass data as String to required fields and in same way it can read data from fields. Once you get data, process it using Java and validate by your own choice.

  113. Nishant Kumar says:

    How to check the presence of element on the Webpage. I have to check whether the element is present or not on Webpage for a textbox and after that print the value shown in the textbox

    1. Hi Nishant,

      You can use isDisplayed() over here. If it returns true then you can proceed for next action/operation.

  114. Been says:

    Dear Mukesh! Hello and thank you from Germany. Where do I post general queries? E.g. regarding nullpointerexceptions etc.?

    1. Hi Been,

      NullPointerException are generic exceptions from Java, you can post your doubts under corresponding topics.

  115. Balal says:

    Hi Mukesh,
    Could you please provide the complete code for Data provider example for more than 50 users login to the FB/Gmail.

    Thanks in advance.

    1. Hi Balal,

      In this case, it is better if you read these data from excel using Apache POI(https://vistasadprojects.com/mukeshotwani-blogs-v2/read-and-write-excel-files-in-selenium/)because right now it is 50, what if it is 500.

  116. pooja says:

    Hi Mukesh,

    Can you please provide some idea on load testing using JMeter and junit to automate the scripts.

    1. Hi Pooja,

      Right now, I don’t have any post specific for JUnit and JMeter.

  117. swati nehete says:

    Hello Mukesh
    Very Very Nice Work. I learnt alot from you java and selenium tutorial. It helped me alot. Thank you so very much.

    1. Hi Swati,

      Its nice to read from you.

  118. Chetan says:

    Hello,I want to develope Hybrid framework…So please give me any idea for developing framework or any video available belong to Hybrid framework

  119. Swopna says:

    Hi Mukesh,
    I have jave knowledge, but not having Selenium knowledge. I am referring your all videos,all videos are awesome . Can you suggest me one book. I want to prepare for Interview for Selenium.

    1. You can subscribe to my newsletter and you will get all Q&A

  120. sonali says:

    how to create test suit

  121. pranav says:

    package apacxhe;
    import java.io.File;
    import java.io.FileInputStream;
    import java.io.FileOutputStream;
    import org.apache.poi.xssf.usermodel.XSSFSheet;
    import org.apache.poi.xssf.usermodel.XSSFWorkbook;
    public class excell2 {
    public static void main(String[] args) throws Exception {
    // TODO Auto-generated method stub
    File f = new File(“C://Users//user//Desktop//tests data.xls”);//it is file path
    FileInputStream fis=new FileInputStream(f);
    XSSFWorkbook wb=new XSSFWorkbook(fis);
    XSSFSheet Sheet1 =wb.getSheetAt(0);
    Sheet1.getRow(0).createCell(2).setCellValue(“Pass”);
    Sheet1.getRow(1).createCell(2).setCellValue(“false”);
    FileOutputStream fout=new FileOutputStream(f);
    wb.write(fout);
    wb.close();
    }
    }
    sir, this is my program and i am getting this
    Exception :-
    Exception in thread “main” java.io.FileNotFoundException: C:\Users\user\Desktop\datadriven.xls (The system cannot find the file specified)
    at java.io.FileInputStream.open0(Native Method)
    at java.io.FileInputStream.open(FileInputStream.java:195)
    at java.io.FileInputStream.(FileInputStream.java:138)
    at apacxhe.excell2.main(excell2.java:15)

    1. Hi Pranav,

      Somewhere your file object f is referencing a file on path(C:\Users\user\Desktop\datadriven.xls). Kindly check this file object.

  122. gowtham says:

    Actually i want to automate a multi window handle,but by using windowHandles() it has giving partial output.is it any other way is possible to autmate same???

    1. Hi Gowtham,

      Could you please explain what is partial output?

      1. Tej says:

        Hi Mukesh
        Can you please explain about TRIRIGA Testing

        1. Hi Tej,

          TRIRAGA looks like some Real Estate & Facility Management related application from IBM. As of now, I am not providing anything which is related to functional/specific domain related knowledge. You are always welcome to ask your doubts wrt technical stuffs for automation.

  123. Roup says:

    Hi Mukesh
    Could you please share post or video regarding the below topic:
    “How to read data from csv file using data provider in selenium webdriver”

      1. Hi Rajesh,

        Thanks again…:)

    1. rajesh says:

      Hi Roup,

      You can check data driven framework with dataprovider in selenium webdriver with below url

      https://learn-selenium-automation-testing.blogspot.in/2017/01/selenium-data-driven-framework-step-by-step.html

      1. Hi Rajesh,

        Thanks for guiding Roup.

  124. Dipal says:

    Hi
    How to create framework for web application? I am new for selenium and want to learn to create web application framework using selenium.

  125. Geetarani Mishra says:

    Hi Mukesh,
    Thank you sooo much for your effort, for making professionals to learn automation testing.It’s simply superb and I am a fan of yours.

    1. Thanks Geetarani 🙂 I am glad to read your comment. Keep in touch and let me know if any help from our side.

    2. murli bagare says:

      Hi Mukesh,
      all your videos are awesome ..
      can u please guide me how to automate static pages of website.

      1. Hi Murli,

        What do you mean by static pages? Selenium automate browser it can be static and dynamic too.

  126. Roup says:

    Hi Mukesh,

    Your Blog is really useful as I am new to selenium and Thank You so much for sharing knowledge.

    I have one question.
    Can we use more than one DataProvider using TestNG ?

    1. Hi Roup,

      Yes, you can have multiple dataprovider but you can use one at a time.

  127. sid says:

    hii.. i have a query.. i have been locating the elements manually using xpath and other things and i have able to write and execute programs using eclipse.. my doubt is that for wat i shud used selenium IDE 2.5.0 ??

    1. Hi Sid,

      If you are using Selenium IDE for locating elements then there is no need for doing this. Without Selenium IDE it is possible.

  128. DARSHANKUMAR says:

    Hi Mukesh,
    Please help me with this.
    While using WebDriver interface it is showing error like WebDriver cant not be resolved to a type. How to handle this?

    1. Hi Darshan,

      Please make sure that you do not have any class which named as WebDriver

  129. Pranay says:

    Hi Mukesh,
    I will be very grateful to you for creating such a learning plateform of automation. Thanks a lot for this.. Suppose the test application is sending emails,then can we test this using selenium? If yes, then please provide the tutorial for this.

    1. Hi Pranay,

      Yes every email application has some API which will help you to automate the overall functionality. Kindly check below link https://developers.google.com/gmail/api/

  130. Manasa says:

    Hi sir..,
    Most of the companies will ask selenium with C# so will u share the videos. i am new to the C#

    1. Hi Manasa,

      I will also post soon. As of now you can refer below blog http://executeautomation.com/blog/selenium-automation-with-c/

  131. hemant says:

    Hi Mukesh I am referring your site,its really helpful and clear my concept …Thanks for providing such content for free.

    1. Your most welcome hemant and really appreciating your learning towards Selenium.

  132. Anusha says:

    Mukesh, have you added any video for finding independent and dependent xpath

  133. Sangram says:

    Hi Mukesh,
    This is Sangram..
    do we test Database using selenium?? like logged in database and search value from table or tally those from table data with application data?

  134. abhijeet says:

    can you prepare video about hybrid framework which has
    2 test case
    2 excel sheet
    and that two test cases capture data from two different excel sheet.

    i tried a lot but i am able to read data for only one test case.

    1. Yes Abhijeet sure I will do that.

  135. Amar says:

    I want to master in selenium webdriver,
    plz suggest me
    I go through no. of vedios on youtube
    but i think ur vedios is osm for learning selenium
    It can be enough to watch ur all vedios for selenium webdriver…???

    1. Hi Amar,

      Yes it will help but you also have to put so much effort for this.

  136. archana says:

    Do you have any project for the practice? Where we can do more practice, where can develop 30-35 testcases then integrate with framework , generate report like this???

  137. sanjay vaish says:

    Hi Mukesh,

    Nice blog …

    can u help me for my query

    System.setProperty(“webdriver.gecko.driver”, “D:\\geckodriver-v0.11.0-win64\\geckodriver.exe”);
    WebDriver driver = new FirefoxDriver();

    System.setProperty(“webdriver.ie.driver”,”D:\\IEDriverServer_x64_2.53.1\\IEDriverServer.exe”);
    WebDriver driver1=new InternetExplorerDriver();

    //To click on login button
    driver.get(“http://192.168.11.53:8089/DedupeDRSUAT/”);
    driver.findElement(By.xpath(“id(‘btnlogin’)”)).click();
    driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
    driver.get(“drs.htm?role=9”);

    //To click on logout button

    driver.findElement(By.xpath(“.//*[@id=’logout’]/a/u”)).click();
    driver.close();

    The above code is works perfectly fine for my Mozilla browser, but when i try for IE11 bowers the logout link doesn’t work, it is only opening site and get stuck

    1. Hi Sanjay,

      I checked your code and found you have not used driver1 that is the reason it is not performing any action.

  138. It’s indeed an excellent roundup of the important Selenium articles. Your youtube videos are also quite helpful. Thanks.

    1. Hey Meenakshi,

      Thank you so much 🙂 Happy Diwali to you and your family.

      1. Mayur says:

        Hello Mukesh Sir I am new to selenium world.I want to be master in selenium. Tell me where to start from.Thanks in advance

        1. Hi Mayur,

          You can start from below video playlist

  139. Kiara says:

    Thanks so much Mukesh.. Your blog is very informative for the starters in automation…

    1. Thanks Kiara keep visting.

  140. Srinivasa says:

    This is very useful for beginners, now i am working as manual tester, planning to move to selenium, this is very useful tutorial

    1. Thanks Srinivasa 🙂 Keep visiting.

  141. Anandh says:

    Hi Mukesh,
    Your tutorial is very useful and very clear for beginners. I have doubt in XML comparison. Is there any possible to compare to XML file and display a result whether XML is same or not.

  142. Devi says:

    Hi mukhesh,
    I’m searching job on testing.I have .net developer background.I have seen loads of videos in youtube.But confusing where to start and where to end.confusing????Plz give me guidence how to get job on testing

    1. Hi Devi,

      you can start automating below app

      http://enterprise.demo.orangehrmlive.com/symfony/web/index.php/auth/login

      Once you face any issue then google it or refer my videos and post for the same.

  143. Aayushi says:

    Hello Sir,
    I wrote the script on login page when it opens the home page, i wrote another test script to open the link but its not opening its get stop after successfully login, please help me is their more code i need to add to perform the further operation

    1. Hi Aayushi,

      What error you are getting ?

  144. Santosh says:

    Well You truly live by this quote “Gaining knowledge, is the first step to wisdom, SHARING it, is the first step to humanity ”
    Very good information about selenium . Thanks Mukesh

    1. Thank you so much Santosh

  145. kd6883 says:

    Good Information on Selenium

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.