Need Help Scraping Fantasy Football Data

Hello,

This may be a beginner question but how would I go about creating a loop that could start at each matchup, scrape the data, and then click the next matchup to the right (to the right of the highlighted green), and do the same thing. I have gotten the data scrapping down so that it works, but is there a way to run a loop to have it scrape through all 6 matchups? Like a ‘For Each Element on Page, Click to the Right’?

Thanks in advance

@GrapeApe

Welcome to the communith

Why do you want to click right when all data is visible?

If you just need to read data then table extraction should be enough

If not if you want to perform some click or other actions then directly use for each ui element and it would loop through each item and you can perform your actions inside

Cheers

Hi Anil,

Sorry, I should have mentioned that those scores act as tabs on the top of the page. So, clicking on the box on the left (the one with 113 and highlighted green) will display data below that I want to scrape, and clicking the tab to the right (136) will display different data below. I am trying to loop through so where it clicks one, scrapes the data below, then clicks the next tab to the right, and scrapes that data until it does all tabs. Is there a way to do that within a loop, so I am not making 6 individual clicks and 6 individual data scrapes?

@GrapeApe

  1. For each ui element and indicate tabs
  2. Inside loop use click and send current element
  3. Next use extract datatable activity or table extraction to get data
  4. Write to excel or anything you need

make sure extract datatable selector does not contain any tab specific info…to make sure indicate on a tab…refresh page and select another tab and try validating and highlighting and select attributes whcih are common across all tab pages tables

Hope this helps

cheers

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.