title: Not able to select element in drop down as element is not interactable
body: <p><a href="https://i.stack.imgur.com/RrW3Q.png" rel="nofollow noreferrer">enter image description here</a><a href="https://i.stack.imgur.com/JFOyN.jpg" rel="nofollow noreferrer">enter image description here</a>    I have a dropdown structure with multiple options to select one below the other. The options remain same only the element to select changes. First element is been selected properly but when it goes for selecting the 2nd element, org.openqa.selenium.ElementNotInteractableException, TimeOutException are been given. Please guide me as I have stuck with my Automation code because of this issue. </p>
  
  <pre><code>I tried various things like JavaScriptExecutor, ExplicitWait etc but all in vain. The things that I tried are being commented in code. Also the xpath I used for first name '//li[@class='ant-select-dropdown-menu-item' and text()='First Name']' same when I use for Middle name,webdriver gives the Element not clickable Exception. Referred other questions related to Element Not Interactable in stack overflow but couldn't find the solution.
  </code></pre>
  
  <p>//Java Code
      List elements = driver.findElements(By.xpath("//*[@class='ant-select-arrow']"));
              for (int i=0; i div:nth-child(3) > div:nth-child(1) > div:nth-child(1) > span:nth-child(2)")).click();
              Thread.sleep(2000);
              driver.findElement(By.xpath("//li[@class='ant-select-dropdown-menu-item' and text()='First Name']")).click();</p>
  
  <pre><code>        Thread.sleep(2000);
          try {
              //driver.findElement(By.cssSelector("div.ant-row:nth-child(2) &gt; div:nth-child(3) &gt; div:nth-child(1) &gt; div:nth-child(1) &gt; span:nth-child(2)")).click();
              elements.get(1).click();
              Thread.sleep(5000);
              //WebDriverWait wait1=new WebDriverWait(driver,10);
              //wait1.untildriver.findElement(By.xpath("//li[@class='ant-select-dropdown-menu-item' and text()='Middle Name']"));
  //          WebElement element1=wait1.until(ExpectedConditions.elementToBeClickable(By.xpath("/html/body/div[5]/div/div/div/ul/li[3]")));
  //          element1.click();
              //WebDriverWait wt= new WebDriverWait(driver,10);
              //wt.until(ExpectedConditions.elementToBeClickable(By.cssSelector("body &gt; div:nth-child(10) &gt; div &gt; div &gt; div &gt; ul &gt; li:nth-child(3)"))).click();
              driver.findElement(By.cssSelector("body &gt; div:nth-child(10) &gt; div &gt; div &gt; div &gt; ul &gt; li:nth-child(3)"));
  
  
          }catch(Exception e) {
              e.printStackTrace();
          }
  
          Thread.sleep(3000);
  
          //driver.findElement(By.cssSelector("div.ant-row:nth-child(3) &gt; div:nth-child(3) &gt; div:nth-child(1) &gt; div:nth-child(1) &gt; span:nth-child(2)")).click();
          elements.get(2).click();
          Thread.sleep(2000);
          driver.findElement(By.cssSelector("body &gt; div:nth-child(11) &gt; div &gt; div &gt; div &gt; ul &gt; li:nth-child(4)")).click();
  
  
          Thread.sleep(2000);
          try {
              //          driver.manage().window().maximize();
              //          JavascriptExecutor jse = (JavascriptExecutor)driver;
              //          Thread.sleep(2000);
              //          jse.executeScript("window.scrollBy(0,250)", "");
              //Thread.sleep(2000);
  
              //driver.findElement(By.cssSelector("div.ant-row:nth-child(4) &gt; div:nth-child(3) &gt; div:nth-child(1) &gt; div:nth-child(1) &gt; span:nth-child(2)")).click();
              elements.get(3).click();
              Thread.sleep(3000);
              //  new WebDriverWait(driver, 30).until(ExpectedConditions.visibilityOfElementLocated(By.xpath("/html/body/div[4]/div/div/div/ul/li[5]")));
              driver.findElement(By.xpath("/html/body/div[7]/div/div/div/ul/li[5]")).click();
          }catch(Exception e) {
              e.printStackTrace();
          }
  
  
  
          Thread.sleep(2000);
          elements.get(4).click();
          //driver.findElement(By.cssSelector("div.ant-row:nth-child(5) &gt; div:nth-child(3) &gt; div:nth-child(1) &gt; div:nth-child(1) &gt; span:nth-child(2)")).click();
          Thread.sleep(2000);
          driver.findElement(By.xpath("/html/body/div[8]/div/div/div/ul/li[6]")).click();
  
          Thread.sleep(2000);
          elements.get(5).click();
          //driver.findElement(By.cssSelector("div.ant-row:nth-child(6) &gt; div:nth-child(3) &gt; div:nth-child(1) &gt; div:nth-child(1) &gt; span:nth-child(2)")).click();
          Thread.sleep(2000);
          driver.findElement(By.xpath("/html/body/div[9]/div/div/div/ul/li[7]")).click();
  
  org.openqa.selenium.ElementNotInteractableException, TimeOutException are been given. Element cannot be scrolled into view error also is been given.
  </code></pre>