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

timeout - Handshake_timeout on RabbitMQ using python and pika from remote vm -

gcc - MinGW's ld cannot perform PE operations on non PE output file -

c# - Search and Add Comment with OpenXML for Word -