0

I am trying to get the names of all the guests attending my event and have selected 'going' on my event.

I go to the event page, click on the X going / Y interested option and a dialog box opens. The dialog box can be scrolled and has to be scrolled to get the list of all the guests of my events. It is a typical scrollable window with lazy loading.

I have tried using execute_script function to scroll down a little but since I don't know enough javascript, I could not modify it to reach the end of the dialog box.

How can I scroll to the end of the dialog box?

1

3 Answers 3

1

If you know the element id you can use this:

from selenium.webdriver.common.action_chains import ActionChains

ActionChains(driver).move_to_element(driver.sl.find_element_by_id('my-id')).perform()
Sign up to request clarification or add additional context in comments.

1 Comment

Since the dialog box has to be loaded each time to reach the end, I do not know at the beginning of my script where I need to stop. So using your method will not work for me
0

Have tried the below options.Try this with your div_element.

driver.execute_script("return arguments[0].scrollIntoView(true);", div_element)

Comments

0

I used zooming out for my dynamic content. Elements get small and you get to fetch 'em all.

driver.execute_script("document.body.style.zoom='zoom %'")

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.