title: org.openqa.selenium.NoSuchElementException even if the xpath is correct and wait was added
body: <p>I am using selenium-java-2.53.jar to hit a website and perform a search operation. After the serach results come, I need to read the data. The website url is <a href="https://340bopais.hrsa.gov/coveredentitysearch" rel="nofollow noreferrer">https://340bopais.hrsa.gov/coveredentitysearch</a> . I put a value in the textbox for 340B ID as CH02123B and click 'Search'. After this the results are shown in a table. Till here, it works fine with selenium. But after this, when I try to read the data by using driver.findElement and By.xpath , I get an exception as org.openqa.selenium.NoSuchElementException: no such element: Unable to locate element. </p>
  
  <p>Below is the part of the HTML source from the search page which comes after I hit Search:</p>
  
  <pre><code>&lt;tr class="rgRow" valign="top" id="ctl00_ContentPlaceHolder1_CoveredEntitySearchGrid_ctl00__0" role="row"&gt;
          &lt;td role="gridcell"&gt;&lt;input id="ctl00_ContentPlaceHolder1_CoveredEntitySearchGrid_ctl00_ctl04_ClientSelectColumnSelectCheckBox" type="checkbox" name="ctl00$ContentPlaceHolder1$CoveredEntitySearchGrid$ctl00$ctl04$ClientSelectColumnSelectCheckBox" title="Select/Deselect Row" role="checkbox" aria-label="ClientSelectColumn checkbox" aria-checked="false"&gt;&lt;/td&gt;&lt;td role="gridcell"&gt;&lt;a title="CH02123B" href="cedetails/12136"&gt;CH02123B&lt;/a&gt;&lt;/td&gt;
          &lt;td role="gridcell"&gt;CH&lt;/td&gt;
          &lt;td role="gridcell"&gt;NEIGHBORHOOD HEALTH SERVICES CORPORATION&lt;/td&gt;
          &lt;td role="gridcell"&gt;Neighborhood Health Center The Healthy Place&lt;/td&gt;
          &lt;td role="gridcell"&gt;427 Darrow Ave&lt;/td&gt;
          &lt;td role="gridcell"&gt;Plainfield&lt;/td&gt;
          &lt;td role="gridcell"&gt;NJ&lt;/td&gt;
          &lt;td role="gridcell"&gt;10/01/2004&lt;/td&gt;
          &lt;td role="gridcell"&gt;&amp;nbsp;&lt;/td&gt;
          &lt;td role="gridcell"&gt;02/13/2017&lt;/td&gt;
  &lt;/tr&gt;
  </code></pre>
  
  <p>I want to read the TD which has content as 'NEIGHBORHOOD HEALTH SERVICES CORPORATION'.
  I got the Xpath from Chrome and used the same in my code. Still I get the exception. I have tried many combinations , but all in vain. </p>
  
  <p>Below is my code:</p>
  
  <pre><code>StackApplication.class.getClassLoader().getResource("driver/chromedriver.exe").getFile();
  WebDriver driverHL = new ChromeDriver();
  driverHL.navigate().to("https://340bopais.hrsa.gov/coveredentitysearch"); 
  driverHL.findElement(By.xpath("//*[@id=\"ContentPlaceHolder1_ceSearchCtrl_txt340BID\"]")).sendKeys("CH02123B");
  driverHL.findElement(By.xpath("//*[@id=\"btnSearch\"]")).click() ; 
  WebDriverWait myDynamicElement = new WebDriverWait(driver, 30);
  myDynamicElement.until(ExpectedConditions.presenceOfElementLocated(By.xpath("//tr[@id=\"ctl00_ContentPlaceHolder1_CoveredEntitySearchGrid_ctl00__0\"]/td[4]")));
  driverHL.findElement(By.xpath("//tr[@id=\"ctl00_ContentPlaceHolder1_CoveredEntitySearchGrid_ctl00__0\"]/td[4]"));
  </code></pre>
  
  <p>Complete stack trace of the exception (with some specific details overriden):</p>
  
  <pre><code>Exception in thread "main" org.openqa.selenium.TimeoutException: Timed out after 30 seconds waiting for presence of element located by: By.xpath: //tr[@id="ctl00_ContentPlaceHolder1_CoveredEntitySearchGrid_ctl00__0"]/td[4]
  Build info: version: '2.53.1', revision: 'a36b8b1cd5757287168e54b817830adce9b0158d', time: '2016-06-30 19:26:09'
  System info: host: 'hostName', ip: '&lt;ip_address&gt;', os.name: '&lt;OS_Name&gt;', os.arch: '&lt;arch&gt;', os.version: '&lt;x.x&gt;', java.version: '1.7.0_13'
  Session ID: 7636dc2ad6277bd827467c2f40c3f322
  Driver info: org.openqa.selenium.chrome.ChromeDriver
  Capabilities [&lt;SomeMachineSpecificData&gt;]
      at org.openqa.selenium.support.ui.WebDriverWait.timeoutException(WebDriverWait.java:80)
      at org.openqa.selenium.support.ui.FluentWait.until(FluentWait.java:261)
      at comm.myProject.MyDownloader.MyApplication.main(StackApplication.java:67)
  Caused by: org.openqa.selenium.NoSuchElementException: no such element: Unable to locate element: {"method":"xpath","selector":"//tr[@id="ctl00_ContentPlaceHolder1_CoveredEntitySearchGrid_ctl00__0"]/td[4]"}
    (Session info: chrome=63.0.3239.108)
    (Driver info: chromedriver=2.34.522940 (1a76f96f66e3ca7b8e57d503b4dd3bccfba87af1),platform=Windows NT 6.1.7601 SP1 x86) (WARNING: The server did not provide any stacktrace information)
  Command duration or timeout: 0 milliseconds
  For documentation on this error, please visit: http://seleniumhq.org/exceptions/no_such_element.html
  Build info: version: '2.53.1', revision: 'a36b8b1cd5757287168e54b817830adce9b0158d', time: '2016-06-30 19:26:09'
  System info: host: 'hostName', ip: '&lt;ip_address&gt;', os.name: '&lt;OS_Name&gt;', os.arch: '&lt;arch&gt;', os.version: '&lt;x.x&gt;', java.version: '1.7.0_13'
  *** Element info: {Using=xpath, value=//tr[@id="ctl00_ContentPlaceHolder1_CoveredEntitySearchGrid_ctl00__0"]/td[4]}
  Session ID: 7636dc2ad6277bd827467c2f40c3f322
  Driver info: org.openqa.selenium.chrome.ChromeDriver
  Capabilities [&lt;specific info&gt;]
      at sun.reflect.GeneratedConstructorAccessor10.newInstance(Unknown Source)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
      at java.lang.reflect.Constructor.newInstance(Unknown Source)
      at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:206)
      at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:158)
      at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:678)
      at org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:363)
      at org.openqa.selenium.remote.RemoteWebDriver.findElementByXPath(RemoteWebDriver.java:500)
      at org.openqa.selenium.By$ByXPath.findElement(By.java:361)
      at org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:355)
      at org.openqa.selenium.support.ui.ExpectedConditions.findElement(ExpectedConditions.java:899)
      at org.openqa.selenium.support.ui.ExpectedConditions.access$000(ExpectedConditions.java:41)
      at org.openqa.selenium.support.ui.ExpectedConditions$6.apply(ExpectedConditions.java:181)
      at org.openqa.selenium.support.ui.ExpectedConditions$6.apply(ExpectedConditions.java:178)
      at org.openqa.selenium.support.ui.FluentWait.until(FluentWait.java:238)
      ... 1 more      
  </code></pre>