title: Selenium Python: How to Scroll Down in a Pop Up window
body: <p>I am working on a Linkedin web scraping project. I am trying to get the list of companies that interest someone (notice I am not using the API). It is a dynamic website, so I would need to scroll down while scraping the names of the companies. I know how to do this in the MAIN window, but since Interest are a pop-up window <a href="https://stackoverflow.com/questions/20986631/how-can-i-scroll-a-web-page-using-selenium-webdriver-in-python">this</a> solution to scroll does not work. My code so far was: </p>
  
  <pre><code>from selenium.webdriver.common.keys import Keys
  bar = driver.find_element_by_xpath('//ul[@class="entity-list row"]')
  bar.send_keys(Keys.END)
  </code></pre>
  
  <p>Since it didn't work, I also tried:</p>
  
  <pre><code>bar = driver.find_element_by_xpath('//ul[@class="entity-list row"]')
  driver.execute_script('arguments[0].scrollTop = arguments[0].scrollHeight', bar)
  </code></pre>
  
  <p>The problem is that I am not acting on the pop up window but in the main one so it has not the desired effect. </p>
  
  <p><a href="https://i.stack.imgur.com/SpSya.png" rel="nofollow noreferrer">enter image description here</a></p>