title: Continue script if search has no results selenium python
body: <p>I automated the export of some reports, based on registration numbers in list RegistrationNr.</p>
  <p>This is the logic:</p>
  <p>Step 1) Type the registration number into the search box (without this, the html code will not be found)</p>
  <p>Step 2) Click on the registration number</p>
  <p>Step 3) Go and export the report of this organization.</p>
  <p>With my current code, if there is a number on the list which is not in the database, the program stops because it has no number to click on. How can I make it look for the next item on the list whenever this happens?</p>
  <p>This is my code:</p>
  <pre><code> for i in RegistrationNr:
  
        driver.find_element(By.XPATH, './/*[@title = &quot;Searchbox&quot;]').send_keys(i)
  
        driver.find_element(By.XPATH, &quot;.//*[@title =&quot; + ' &quot;'+ i +'&quot;' + &quot;]&quot;).click()
  
        driver.find_element(By.XPATH, './/*[@title = &quot;Number&quot;]').click()
  </code></pre>
  <p>Thanks!</p>