title: unable to retrieve the Table th tag value using webdriver with java
body: <p>From the below html i want to check each row in the table header value and if matched need retrieve the td value</p>
  
  <p>below is my html </p>
  
  <pre><code>&lt;table class="span-5" id="summaryTable" title="Table showing Summary data"&gt;
  &lt;tbody&gt;
  &lt;tr&gt;
  &lt;th class="width-40" id="num"&gt;
  &lt;a href=" " aria-label=" " title="" class="ui-link"&gt;(12) App no&lt;/a&gt;:
  &lt;/th&gt;
  &lt;td headers="num"&gt;
  &lt;a href=" " aria-label=" " title=" " class="ui-link"&gt;(11)&lt;/a&gt; 
  &lt;strong&gt;2796179&lt;/strong&gt;
  &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr&gt;
  &lt;th class="noLines alignLeft width35" id="EnglishTitle"&gt; 
  &lt;a href=" " aria-label=" " title=" " class="ui-link"&gt;(54) English Title&lt;/a&gt;:
  &lt;/th&gt;
  &lt;td class="noLines alignLeft width65" headers="EnglishTitle"&gt;
  FRAME BIT-SIZE ALLOCATION
  &lt;/td&gt;
  &lt;/tr&gt;   
  &lt;tr&gt;
  &lt;/tbody&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>i want to collect the each th tag value (i.e <code>(12) App no</code> <code>(54) English Title</code>)</p>
  
  <p>my java code</p>
  
  <pre><code>WebElement summary = driver.findElement(By.xpath("//*[@id='summaryTable']/tbody"));
                  List&lt;WebElement&gt;rows = summary.findElements(By.tagName("tr"));
                  for (int i=1;i&lt;=rows.size();i++){
  
                      String dc = driver.findElement(By.xpath("//*[@id='summaryTable']/tbody/tr["+i+"]/td/th/a")).getText();
                      if (dc.equalsIgnoreCase("(12) App no")){
                           appNo = driver.findElement(By.xpath("//*[@id='summaryTable']/tbody/tr["+i+"]/td/strong")).getText();
                      }                       
                  }
  </code></pre>
  
  <p>but i'm getting no such element: Unable to locate element: <code>{"method":"xpath","selector":"//*[@id='summaryTable']/tbody/tr[1]/td/th/a"}</code></p>