title: Cannot switchTo frames -- keep getting AttributeError
body: <p>my first time posting. My apologies in advance for any missteps. </p>
  
  <p>I am writing in Python, using Selenium, trying to scrape some information from some webpages. </p>
  
  <p>I can not seem to solve this puzzle after two days of searching-trying-searching.</p>
  
  <p>My issue is this; while trying to sign in to a website w/Selenium/Python, I am unable to 'find element' to log in. After much searching, I realize that I may need to switch frames to find the element. I've tried the <code>switchTo</code> (or switch_to) command many different ways--and I keep getting the message </p>
  
  <blockquote>
    <p>"Attribute error: SwitchTo instance has no <strong>call</strong> method". </p>
  </blockquote>
  
  <p>I will post the most recent attempt (please let me know if I can provide any further information): </p>
  
  <p>In selenium:</p>
  
  <pre><code>waitUntilReady(browser)  
  browser.switch_to().frame(browser.findElement(By.ID("iframe[id='credentials']")))
  elem = WebDriverWait(browser, 60).until(EC.presence_of_element_located((By.NAME, "Ecom_User_ID")))
  elem = browser.find_element_by_name("Ecom_User_ID")
  elem.send_keys("frustrated")
  </code></pre>
  
  <p>What gets returned (in terminal):</p>
  
  <blockquote>
    <p>File "someproj.py", line 56, in 
            browser.switch_to().frame(browser.findElement(By.ID("iframe[id='credentials']")))
        AttributeError: SwitchTo instance has no <strong>call</strong> method</p>
  </blockquote>
  
  <p>html form website:</p>
  
  <pre><code> &lt;!DOCTYPE html&gt;
  
      &lt;html lang="en" webdriver="true"&gt;
          &lt;head&gt;&lt;/head&gt;
          &lt;body onload="onloadhandler()"&gt;
              &lt;div class="m-header"&gt;&lt;/div&gt;
              &lt;div class="container"&gt;
                  &lt;div class="header"&gt;&lt;/div&gt;
                  &lt;div class="ten columns"&gt;
                      &lt;h2&gt;&lt;/h2&gt;
                      &lt;iframe id="loginsubtab" height="375" frameborder="0" width="100%" src="/nidp/jsp/content.jsp?sid=0&amp;id=289&amp;sid=0" scrolling="no"&gt;
                          #document
                              &lt;!DOCTYPE html&gt;
                              &lt;html lang="en" webdriver="true"&gt;
                                  &lt;head&gt;&lt;/head&gt;
                                  &lt;body onload="onloadhandler('selectedCard')"&gt;
                                      &lt;div id="content"&gt;
                                          &lt;table border="0" width="100%"&gt;
                                              &lt;tbody&gt;
                                                  &lt;tr&gt;
                                                      &lt;td&gt;
                                                          &lt;iframe id="credentials" height="375" frameborder="0" width="100%" src="/nidp/saml2/sso?id=289&amp;sid=0&amp;option=credential&amp;sid=0" scrolling="no"&gt;
                                                              #document
  </code></pre>
  
  <p>Many thanks for any ideas or guidance!!!</p>