title: iframe within iframe cant find element
body: <p>Currently trying to find an element that is located in an iframe that is within another iframe. I have not been successful in locating the element. To add an extra challenge the first iframe doesnt contain an ID or Name.</p>
  <p><a href="https://i.stack.imgur.com/kflDT.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/kflDT.png" alt="enter image description here" /></a></p>
  <p><strong>My current code looks like this:</strong></p>
  <pre><code>    //Open Statement Screen
      [Test, Category(&quot;Smoke Test&quot;)]
      public void StatementsDisplay()
      {
          var statementsPage = new StatementsPage(driver);
          WebDriverWait webDriverWait = new(driver, TimeSpan.FromSeconds(15));
  
          //Click link to Statements page
          statementsPage.statementsLink.Click();
  
          //Waits for and switches to iframe then verifies element is present
          webDriverWait.Until(ExpectedConditions.FrameToBeAvailableAndSwitchToIt(By.XPath(&quot;//iframe[contains(@src,'/eStatements/eStatements.aspx?internalNavHidden=true&amp;internalThemeName=connect')]&quot;)));
          webDriverWait.Until(ExpectedConditions.FrameToBeAvailableAndSwitchToIt(By.Id(&quot;cphPageContent_EstatementFrame&quot;)));
          Assert.IsTrue(statementsPage.pinField.Displayed);
      }
  </code></pre>
  <p><strong>Here is the error:</strong></p>
  <p><a href="https://i.stack.imgur.com/G9oii.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/G9oii.png" alt="enter image description here" /></a></p>
  <p><strong>StatementsPage.get_pinField() line 19:</strong></p>
  <pre><code>public IWebElement pinField =&gt; driver.FindElement(By.XPath(&quot;//input[contains(@id,'pin')]&quot;));
  </code></pre>
  <p><strong>SmokeTests`1.StatementsDisplay() line 155:</strong></p>
  <pre><code>Assert.IsTrue(statementsPage.pinField.Displayed);
  </code></pre>