Selenium Calendar: Months and Dates Selections: What i'm doing wrongJava Date vs CalendarI want to get Year, Month, Day, etc from Java Date to compare with Gregorian Calendar date in Java. Is this possible?parse the following string to year, month, date, hourOfDay, minute, secondHow to select multiple rows at different place in a table using Selenium WebdriverHow to get another Calendar result from same instance?How to set a date as input in java?java.text.ParseException Unparsable Date: “0”What is an easy way to output a stored gregorian calendar to be used output to xmlHow to Click loop and click on all xpath with attribute and print in console get text?Why is Calendar value different?

A social experiment. What is the worst that can happen?

What was the exact wording from Ivanhoe of this advice on how to free yourself from slavery?

Is it safe to use olive oil to clean the ear wax?

What is the evidence for the "tyranny of the majority problem" in a direct democracy context?

Drawing ramified coverings with tikz

Fear of getting stuck on one programming language / technology that is not used in my country

Closed-form expression for certain product

Aragorn's "guise" in the Orthanc Stone

Why do compilers behave differently when static_cast(ing) a function to void*?

How should I respond when I lied about my education and the company finds out through background check?

What are the purposes of autoencoders?

Should I stop contributing to retirement accounts?

Should I outline or discovery write my stories?

Why Shazam when there is already Superman?

Why did the EU agree to delay the Brexit deadline?

The screen of my macbook suddenly broken down how can I do to recover

Is the U.S. Code copyrighted by the Government?

What should you do if you miss a job interview (deliberately)?

How to implement a feedback to keep the DC gain at zero for this conceptual passive filter?

Store Credit Card Information in Password Manager?

Loading commands from file

Longest common substring in linear time

Is there a name for this algorithm to calculate the concentration of a mixture of two solutions containing the same solute?

Why should universal income be universal?



Selenium Calendar: Months and Dates Selections: What i'm doing wrong


Java Date vs CalendarI want to get Year, Month, Day, etc from Java Date to compare with Gregorian Calendar date in Java. Is this possible?parse the following string to year, month, date, hourOfDay, minute, secondHow to select multiple rows at different place in a table using Selenium WebdriverHow to get another Calendar result from same instance?How to set a date as input in java?java.text.ParseException Unparsable Date: “0”What is an easy way to output a stored gregorian calendar to be used output to xmlHow to Click loop and click on all xpath with attribute and print in console get text?Why is Calendar value different?













0















i'm trying to select Months and Dates from a calendar (www.booking.com) for practice purposes but i can not get it to select the month, if the month is into left panel. Probably i'm missing something. Can anyone give me a hint? or make an assist, it would be much appreciated. Thanks in advance.



My Code:



 public void calendar() throws InterruptedException {


String selectDate = "6/11/2020";
Date d = new Date(selectDate);

SimpleDateFormat years = new SimpleDateFormat("yyyy");
SimpleDateFormat months = new SimpleDateFormat("MMMM");
SimpleDateFormat days = new SimpleDateFormat("d");
String year = years.format(d);
String month = months.format(d);
String day = days.format(d);
String gap = " ";
String search = month + gap + year;


while (!driver.findElement(By.xpath("//div[@class='xp-calendar']/div/div/div/div/*[contains(@class,'bui-calendar__month')]")).getText().equalsIgnoreCase(search))
Thread.sleep(1000);
driver.findElement(By.xpath("//div[@class='xp-calendar']/div/div/div[2]")).click();



int coutDays = driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).size();

for (int i = 0; i < coutDays; i++)
String searchingDay = driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).get(i).getText();
if (searchingDay.equalsIgnoreCase(day))
Thread.sleep(1000);
driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).get(i).click();
break;












share|improve this question
























  • What exactly is your question? I see a lot of code, unexplained objects such as By, and no example data. Are you asking how to search a string for a portion matching the name of a month and a year? If so, give example date and delete the xpath distraction.

    – Basil Bourque
    Mar 7 at 22:53












  • FYI, the terribly troublesome old date-time classes such as java.util.Date, java.util.Calendar, and java.text.SimpleDateFormat are now legacy, supplanted by the java.time classes built into Java 8 and later. See Tutorial by Oracle.

    – Basil Bourque
    Mar 7 at 22:53











  • What happens when the month is in the left panel? I don't see the code to open the date-picker ui as well.

    – Kamal
    Mar 8 at 2:28











  • @Kamal, from the left side, it picks date normally, the problem is when it reaches the last month of the calendar. As it begins all months pass from the left side, so it reads and selects normally, but at the last month that remains at the right side....it stacks.

    – Proko
    Mar 8 at 9:15






  • 1





    Please do not update your question with an answer, but post an answer to your own question. See stackoverflow.com/help/self-answer

    – SiKing
    Mar 8 at 23:10















0















i'm trying to select Months and Dates from a calendar (www.booking.com) for practice purposes but i can not get it to select the month, if the month is into left panel. Probably i'm missing something. Can anyone give me a hint? or make an assist, it would be much appreciated. Thanks in advance.



My Code:



 public void calendar() throws InterruptedException {


String selectDate = "6/11/2020";
Date d = new Date(selectDate);

SimpleDateFormat years = new SimpleDateFormat("yyyy");
SimpleDateFormat months = new SimpleDateFormat("MMMM");
SimpleDateFormat days = new SimpleDateFormat("d");
String year = years.format(d);
String month = months.format(d);
String day = days.format(d);
String gap = " ";
String search = month + gap + year;


while (!driver.findElement(By.xpath("//div[@class='xp-calendar']/div/div/div/div/*[contains(@class,'bui-calendar__month')]")).getText().equalsIgnoreCase(search))
Thread.sleep(1000);
driver.findElement(By.xpath("//div[@class='xp-calendar']/div/div/div[2]")).click();



int coutDays = driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).size();

for (int i = 0; i < coutDays; i++)
String searchingDay = driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).get(i).getText();
if (searchingDay.equalsIgnoreCase(day))
Thread.sleep(1000);
driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).get(i).click();
break;












share|improve this question
























  • What exactly is your question? I see a lot of code, unexplained objects such as By, and no example data. Are you asking how to search a string for a portion matching the name of a month and a year? If so, give example date and delete the xpath distraction.

    – Basil Bourque
    Mar 7 at 22:53












  • FYI, the terribly troublesome old date-time classes such as java.util.Date, java.util.Calendar, and java.text.SimpleDateFormat are now legacy, supplanted by the java.time classes built into Java 8 and later. See Tutorial by Oracle.

    – Basil Bourque
    Mar 7 at 22:53











  • What happens when the month is in the left panel? I don't see the code to open the date-picker ui as well.

    – Kamal
    Mar 8 at 2:28











  • @Kamal, from the left side, it picks date normally, the problem is when it reaches the last month of the calendar. As it begins all months pass from the left side, so it reads and selects normally, but at the last month that remains at the right side....it stacks.

    – Proko
    Mar 8 at 9:15






  • 1





    Please do not update your question with an answer, but post an answer to your own question. See stackoverflow.com/help/self-answer

    – SiKing
    Mar 8 at 23:10













0












0








0








i'm trying to select Months and Dates from a calendar (www.booking.com) for practice purposes but i can not get it to select the month, if the month is into left panel. Probably i'm missing something. Can anyone give me a hint? or make an assist, it would be much appreciated. Thanks in advance.



My Code:



 public void calendar() throws InterruptedException {


String selectDate = "6/11/2020";
Date d = new Date(selectDate);

SimpleDateFormat years = new SimpleDateFormat("yyyy");
SimpleDateFormat months = new SimpleDateFormat("MMMM");
SimpleDateFormat days = new SimpleDateFormat("d");
String year = years.format(d);
String month = months.format(d);
String day = days.format(d);
String gap = " ";
String search = month + gap + year;


while (!driver.findElement(By.xpath("//div[@class='xp-calendar']/div/div/div/div/*[contains(@class,'bui-calendar__month')]")).getText().equalsIgnoreCase(search))
Thread.sleep(1000);
driver.findElement(By.xpath("//div[@class='xp-calendar']/div/div/div[2]")).click();



int coutDays = driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).size();

for (int i = 0; i < coutDays; i++)
String searchingDay = driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).get(i).getText();
if (searchingDay.equalsIgnoreCase(day))
Thread.sleep(1000);
driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).get(i).click();
break;












share|improve this question
















i'm trying to select Months and Dates from a calendar (www.booking.com) for practice purposes but i can not get it to select the month, if the month is into left panel. Probably i'm missing something. Can anyone give me a hint? or make an assist, it would be much appreciated. Thanks in advance.



My Code:



 public void calendar() throws InterruptedException {


String selectDate = "6/11/2020";
Date d = new Date(selectDate);

SimpleDateFormat years = new SimpleDateFormat("yyyy");
SimpleDateFormat months = new SimpleDateFormat("MMMM");
SimpleDateFormat days = new SimpleDateFormat("d");
String year = years.format(d);
String month = months.format(d);
String day = days.format(d);
String gap = " ";
String search = month + gap + year;


while (!driver.findElement(By.xpath("//div[@class='xp-calendar']/div/div/div/div/*[contains(@class,'bui-calendar__month')]")).getText().equalsIgnoreCase(search))
Thread.sleep(1000);
driver.findElement(By.xpath("//div[@class='xp-calendar']/div/div/div[2]")).click();



int coutDays = driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).size();

for (int i = 0; i < coutDays; i++)
String searchingDay = driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).get(i).getText();
if (searchingDay.equalsIgnoreCase(day))
Thread.sleep(1000);
driver.findElements(By.xpath("//div[@class='xp-calendar']/div/div/div/div/table/tbody/tr/td")).get(i).click();
break;









java selenium






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 9 at 12:59







Proko

















asked Mar 7 at 22:47









ProkoProko

156




156












  • What exactly is your question? I see a lot of code, unexplained objects such as By, and no example data. Are you asking how to search a string for a portion matching the name of a month and a year? If so, give example date and delete the xpath distraction.

    – Basil Bourque
    Mar 7 at 22:53












  • FYI, the terribly troublesome old date-time classes such as java.util.Date, java.util.Calendar, and java.text.SimpleDateFormat are now legacy, supplanted by the java.time classes built into Java 8 and later. See Tutorial by Oracle.

    – Basil Bourque
    Mar 7 at 22:53











  • What happens when the month is in the left panel? I don't see the code to open the date-picker ui as well.

    – Kamal
    Mar 8 at 2:28











  • @Kamal, from the left side, it picks date normally, the problem is when it reaches the last month of the calendar. As it begins all months pass from the left side, so it reads and selects normally, but at the last month that remains at the right side....it stacks.

    – Proko
    Mar 8 at 9:15






  • 1





    Please do not update your question with an answer, but post an answer to your own question. See stackoverflow.com/help/self-answer

    – SiKing
    Mar 8 at 23:10

















  • What exactly is your question? I see a lot of code, unexplained objects such as By, and no example data. Are you asking how to search a string for a portion matching the name of a month and a year? If so, give example date and delete the xpath distraction.

    – Basil Bourque
    Mar 7 at 22:53












  • FYI, the terribly troublesome old date-time classes such as java.util.Date, java.util.Calendar, and java.text.SimpleDateFormat are now legacy, supplanted by the java.time classes built into Java 8 and later. See Tutorial by Oracle.

    – Basil Bourque
    Mar 7 at 22:53











  • What happens when the month is in the left panel? I don't see the code to open the date-picker ui as well.

    – Kamal
    Mar 8 at 2:28











  • @Kamal, from the left side, it picks date normally, the problem is when it reaches the last month of the calendar. As it begins all months pass from the left side, so it reads and selects normally, but at the last month that remains at the right side....it stacks.

    – Proko
    Mar 8 at 9:15






  • 1





    Please do not update your question with an answer, but post an answer to your own question. See stackoverflow.com/help/self-answer

    – SiKing
    Mar 8 at 23:10
















What exactly is your question? I see a lot of code, unexplained objects such as By, and no example data. Are you asking how to search a string for a portion matching the name of a month and a year? If so, give example date and delete the xpath distraction.

– Basil Bourque
Mar 7 at 22:53






What exactly is your question? I see a lot of code, unexplained objects such as By, and no example data. Are you asking how to search a string for a portion matching the name of a month and a year? If so, give example date and delete the xpath distraction.

– Basil Bourque
Mar 7 at 22:53














FYI, the terribly troublesome old date-time classes such as java.util.Date, java.util.Calendar, and java.text.SimpleDateFormat are now legacy, supplanted by the java.time classes built into Java 8 and later. See Tutorial by Oracle.

– Basil Bourque
Mar 7 at 22:53





FYI, the terribly troublesome old date-time classes such as java.util.Date, java.util.Calendar, and java.text.SimpleDateFormat are now legacy, supplanted by the java.time classes built into Java 8 and later. See Tutorial by Oracle.

– Basil Bourque
Mar 7 at 22:53













What happens when the month is in the left panel? I don't see the code to open the date-picker ui as well.

– Kamal
Mar 8 at 2:28





What happens when the month is in the left panel? I don't see the code to open the date-picker ui as well.

– Kamal
Mar 8 at 2:28













@Kamal, from the left side, it picks date normally, the problem is when it reaches the last month of the calendar. As it begins all months pass from the left side, so it reads and selects normally, but at the last month that remains at the right side....it stacks.

– Proko
Mar 8 at 9:15





@Kamal, from the left side, it picks date normally, the problem is when it reaches the last month of the calendar. As it begins all months pass from the left side, so it reads and selects normally, but at the last month that remains at the right side....it stacks.

– Proko
Mar 8 at 9:15




1




1





Please do not update your question with an answer, but post an answer to your own question. See stackoverflow.com/help/self-answer

– SiKing
Mar 8 at 23:10





Please do not update your question with an answer, but post an answer to your own question. See stackoverflow.com/help/self-answer

– SiKing
Mar 8 at 23:10












2 Answers
2






active

oldest

votes


















1














you can use the css to select the calendar date.



driver.findElement(By.cssSelector("td[data-date='2019-03-21']")).click();


Make sure you pass the date in "YYYY-MM-DD" format.



Here is the code if you want to try in your console first.



document.querySelector('td[data-date="2019-03-21"]').click()


You don't have to open the date picker, just navigate to the page and run the above.






share|improve this answer























  • thanks for the hint, I will try it and I will respond

    – Proko
    Mar 8 at 9:18











  • Found the solution: i used dynamic xpath to select months and dates, i post the code if anyone interested

    – Proko
    Mar 8 at 21:17



















0














Correct Code:



String date = "10-June 2020";
String splitter[]= date.split("-");
String checkInMonth_Year = splitter[1];
String checkInDay = splitter[0];


List<WebElement> a = driver.findElements(By.xpath("//div[@class='bui-calendar']/div/div/div/div"));

for (int i=0; i<a.size(); i++)

System.out.println(a.get(i).getText());
if (a.get(i).getText().equals(checkInMonth_Year))

List<WebElement> days = driver.findElements(By.xpath("//div[@class='bui-calendar']/div/div/div["+(i+1)+"]/table/tbody/tr/td[@class='bui-calendar__date']"));
for (WebElement d:days)

if (d.getText().equals(checkInDay))

d.click();
return;






pauseFor1Sec();
driver.findElement(By.xpath("//div[contains(@class,'bui-calendar__control bui-calendar__control--next')]")).click();
calendar();





share|improve this answer






















    Your Answer






    StackExchange.ifUsing("editor", function ()
    StackExchange.using("externalEditor", function ()
    StackExchange.using("snippets", function ()
    StackExchange.snippets.init();
    );
    );
    , "code-snippets");

    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "1"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader:
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    ,
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













    draft saved

    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55054033%2fselenium-calendar-months-and-dates-selections-what-im-doing-wrong%23new-answer', 'question_page');

    );

    Post as a guest















    Required, but never shown

























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    1














    you can use the css to select the calendar date.



    driver.findElement(By.cssSelector("td[data-date='2019-03-21']")).click();


    Make sure you pass the date in "YYYY-MM-DD" format.



    Here is the code if you want to try in your console first.



    document.querySelector('td[data-date="2019-03-21"]').click()


    You don't have to open the date picker, just navigate to the page and run the above.






    share|improve this answer























    • thanks for the hint, I will try it and I will respond

      – Proko
      Mar 8 at 9:18











    • Found the solution: i used dynamic xpath to select months and dates, i post the code if anyone interested

      – Proko
      Mar 8 at 21:17
















    1














    you can use the css to select the calendar date.



    driver.findElement(By.cssSelector("td[data-date='2019-03-21']")).click();


    Make sure you pass the date in "YYYY-MM-DD" format.



    Here is the code if you want to try in your console first.



    document.querySelector('td[data-date="2019-03-21"]').click()


    You don't have to open the date picker, just navigate to the page and run the above.






    share|improve this answer























    • thanks for the hint, I will try it and I will respond

      – Proko
      Mar 8 at 9:18











    • Found the solution: i used dynamic xpath to select months and dates, i post the code if anyone interested

      – Proko
      Mar 8 at 21:17














    1












    1








    1







    you can use the css to select the calendar date.



    driver.findElement(By.cssSelector("td[data-date='2019-03-21']")).click();


    Make sure you pass the date in "YYYY-MM-DD" format.



    Here is the code if you want to try in your console first.



    document.querySelector('td[data-date="2019-03-21"]').click()


    You don't have to open the date picker, just navigate to the page and run the above.






    share|improve this answer













    you can use the css to select the calendar date.



    driver.findElement(By.cssSelector("td[data-date='2019-03-21']")).click();


    Make sure you pass the date in "YYYY-MM-DD" format.



    Here is the code if you want to try in your console first.



    document.querySelector('td[data-date="2019-03-21"]').click()


    You don't have to open the date picker, just navigate to the page and run the above.







    share|improve this answer












    share|improve this answer



    share|improve this answer










    answered Mar 8 at 4:45









    supputurisupputuri

    66848




    66848












    • thanks for the hint, I will try it and I will respond

      – Proko
      Mar 8 at 9:18











    • Found the solution: i used dynamic xpath to select months and dates, i post the code if anyone interested

      – Proko
      Mar 8 at 21:17


















    • thanks for the hint, I will try it and I will respond

      – Proko
      Mar 8 at 9:18











    • Found the solution: i used dynamic xpath to select months and dates, i post the code if anyone interested

      – Proko
      Mar 8 at 21:17

















    thanks for the hint, I will try it and I will respond

    – Proko
    Mar 8 at 9:18





    thanks for the hint, I will try it and I will respond

    – Proko
    Mar 8 at 9:18













    Found the solution: i used dynamic xpath to select months and dates, i post the code if anyone interested

    – Proko
    Mar 8 at 21:17






    Found the solution: i used dynamic xpath to select months and dates, i post the code if anyone interested

    – Proko
    Mar 8 at 21:17














    0














    Correct Code:



    String date = "10-June 2020";
    String splitter[]= date.split("-");
    String checkInMonth_Year = splitter[1];
    String checkInDay = splitter[0];


    List<WebElement> a = driver.findElements(By.xpath("//div[@class='bui-calendar']/div/div/div/div"));

    for (int i=0; i<a.size(); i++)

    System.out.println(a.get(i).getText());
    if (a.get(i).getText().equals(checkInMonth_Year))

    List<WebElement> days = driver.findElements(By.xpath("//div[@class='bui-calendar']/div/div/div["+(i+1)+"]/table/tbody/tr/td[@class='bui-calendar__date']"));
    for (WebElement d:days)

    if (d.getText().equals(checkInDay))

    d.click();
    return;






    pauseFor1Sec();
    driver.findElement(By.xpath("//div[contains(@class,'bui-calendar__control bui-calendar__control--next')]")).click();
    calendar();





    share|improve this answer



























      0














      Correct Code:



      String date = "10-June 2020";
      String splitter[]= date.split("-");
      String checkInMonth_Year = splitter[1];
      String checkInDay = splitter[0];


      List<WebElement> a = driver.findElements(By.xpath("//div[@class='bui-calendar']/div/div/div/div"));

      for (int i=0; i<a.size(); i++)

      System.out.println(a.get(i).getText());
      if (a.get(i).getText().equals(checkInMonth_Year))

      List<WebElement> days = driver.findElements(By.xpath("//div[@class='bui-calendar']/div/div/div["+(i+1)+"]/table/tbody/tr/td[@class='bui-calendar__date']"));
      for (WebElement d:days)

      if (d.getText().equals(checkInDay))

      d.click();
      return;






      pauseFor1Sec();
      driver.findElement(By.xpath("//div[contains(@class,'bui-calendar__control bui-calendar__control--next')]")).click();
      calendar();





      share|improve this answer

























        0












        0








        0







        Correct Code:



        String date = "10-June 2020";
        String splitter[]= date.split("-");
        String checkInMonth_Year = splitter[1];
        String checkInDay = splitter[0];


        List<WebElement> a = driver.findElements(By.xpath("//div[@class='bui-calendar']/div/div/div/div"));

        for (int i=0; i<a.size(); i++)

        System.out.println(a.get(i).getText());
        if (a.get(i).getText().equals(checkInMonth_Year))

        List<WebElement> days = driver.findElements(By.xpath("//div[@class='bui-calendar']/div/div/div["+(i+1)+"]/table/tbody/tr/td[@class='bui-calendar__date']"));
        for (WebElement d:days)

        if (d.getText().equals(checkInDay))

        d.click();
        return;






        pauseFor1Sec();
        driver.findElement(By.xpath("//div[contains(@class,'bui-calendar__control bui-calendar__control--next')]")).click();
        calendar();





        share|improve this answer













        Correct Code:



        String date = "10-June 2020";
        String splitter[]= date.split("-");
        String checkInMonth_Year = splitter[1];
        String checkInDay = splitter[0];


        List<WebElement> a = driver.findElements(By.xpath("//div[@class='bui-calendar']/div/div/div/div"));

        for (int i=0; i<a.size(); i++)

        System.out.println(a.get(i).getText());
        if (a.get(i).getText().equals(checkInMonth_Year))

        List<WebElement> days = driver.findElements(By.xpath("//div[@class='bui-calendar']/div/div/div["+(i+1)+"]/table/tbody/tr/td[@class='bui-calendar__date']"));
        for (WebElement d:days)

        if (d.getText().equals(checkInDay))

        d.click();
        return;






        pauseFor1Sec();
        driver.findElement(By.xpath("//div[contains(@class,'bui-calendar__control bui-calendar__control--next')]")).click();
        calendar();






        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Mar 9 at 12:59









        ProkoProko

        156




        156



























            draft saved

            draft discarded
















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid


            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.

            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55054033%2fselenium-calendar-months-and-dates-selections-what-im-doing-wrong%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Identity Server 4 is not redirecting to Angular app after login2019 Community Moderator ElectionIdentity Server 4 and dockerIdentityserver implicit flow unauthorized_clientIdentityServer Hybrid Flow - Access Token is null after user successful loginIdentity Server to MVC client : Page Redirect After loginLogin with Steam OpenId(oidc-client-js)Identity Server 4+.NET Core 2.0 + IdentityIdentityServer4 post-login redirect not working in Edge browserCall to IdentityServer4 generates System.NullReferenceException: Object reference not set to an instance of an objectIdentityServer4 without HTTPS not workingHow to get Authorization code from identity server without login form

            2005 Ahvaz unrest Contents Background Causes Casualties Aftermath See also References Navigation menue"At Least 10 Are Killed by Bombs in Iran""Iran"Archived"Arab-Iranians in Iran to make April 15 'Day of Fury'"State of Mind, State of Order: Reactions to Ethnic Unrest in the Islamic Republic of Iran.10.1111/j.1754-9469.2008.00028.x"Iran hangs Arab separatists"Iran Overview from ArchivedConstitution of the Islamic Republic of Iran"Tehran puzzled by forged 'riots' letter""Iran and its minorities: Down in the second class""Iran: Handling Of Ahvaz Unrest Could End With Televised Confessions""Bombings Rock Iran Ahead of Election""Five die in Iran ethnic clashes""Iran: Need for restraint as anniversary of unrest in Khuzestan approaches"Archived"Iranian Sunni protesters killed in clashes with security forces"Archived

            Can't initialize raids on a new ASUS Prime B360M-A motherboard2019 Community Moderator ElectionSimilar to RAID config yet more like mirroring solution?Can't get motherboard serial numberWhy does the BIOS entry point start with a WBINVD instruction?UEFI performance Asus Maximus V Extreme