python - Selenium scroll to the bottom does not work properly -


i'm trying scroll bottom of web page scrolls once , stay on position , there's big part of page left.

i use this: _inst.driver.execute_script("window.scrollto(0, document.body.scrollheight);")

do know problem?

edit: there way tell selenium has scroll absolute bottom of page or should scroll amount of times? example 5?

to scroll bottom of page, can send ctrl+end 1 of elements:

from selenium.webdriver.common.keys import keys element = driver.find_element_by_ ... element.send_keys(keys.control , keys.end) 

to find element, there many options available (see here)

see here more info

and these questions/answers:

first

second


Comments

Popular posts from this blog

powershell Start-Process exit code -1073741502 when used with Credential from a windows service environment -

twig - Using Twigbridge in a Laravel 5.1 Package -

c# - LINQ join Entities from HashSet's, Join vs Dictionary vs HashSet performance -