title: How to verify multiple values with xpath or store a value
body: <p>My xpath expression is as follows: </p>
  
  <pre><code>//ep:getSwitchListResponse[1]/result[1]/item[position() &gt;1 and position() &lt;= last()]/ipAddress[1]/text()
  </code></pre>
  
  <p>I want to get the value of <code>position()</code> and use it to verify the name . something like</p>
  
  <pre><code>//ep:getSwitchListResponse[1]/result[1]/**item[Position()FromPreviousQuery**)]/name[1]/text() 
  </code></pre>
  
  <p>Is this possible to do both in one xpath expression?</p>