Kev 69 Posted January 25, 2013 Report Share Posted January 25, 2013 Hi all, I'm working with a Google spreadsheet and what I need is to be able to scrape the number of rows that have data in them. In this public spreadsheet you can see there are three rows: https://docs.google.com/spreadsheet/ccc?key=0ArxcY3eOFl_CdE41MzlZSFEyeEhaWGdqUlI2N3ZOd2c I essentially need to return the value of the number of rows that have data in them. I dont really want to download anything - I'd much rather scrape the information from the page. Thanks for the help guys. Kevin Quote Link to post Share on other sites
Kev 69 Posted January 25, 2013 Author Report Share Posted January 25, 2013 Got a solution - and works quite well. Here's the code: clear list(%rows) navigate("https://docs.google.com/spreadsheet/ccc?key=0ArxcY3eOFl_CdE41MzlZSFEyeEhaWGdqUlI2N3ZOd2c#gid=0", "Wait") wait for browser event("Page Loaded", "") wait(1) add list to list(%rows, $scrape attribute(<class=w"g-0-*">, "innertext"), "Don\'t Delete", "Global") wait(1) set(#listtotal, $subtract($list total(%rows), 6), "Global") wait(1) set(#listtotal2, $divide(#listtotal, 6), "Global")In the interests of cleaning up my code is there a better way to do this? 1 Quote Link to post Share on other sites
littledevil 0 Posted January 10, 2016 Report Share Posted January 10, 2016 how to scrape the data from googlesheet? Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.