简体   繁体   中英

Copying specific data from a website to excel

A friend of mine has asked me to figure out a way of getting information from a website and putting it into an excel file.

This is the website in question: http://www.manta.com/world/North+America/Canada/Newfoundland/grocery_stores--B619B/#Location

He wishes to have an excel file with a list of all the names, addresses and phone numbers of all the results of his search.

So far I'm stumped in coming up with an idea. I'm fairly new to internet programming.

I was thinking that maybe I could create a greasemonkey userscript which would search for all the required data on the page and at the click of a button open a pop-up which would have the data in CSV format which could then be copied and pasted into excel. However the phone numbers aren't on the search results page so I don't think this is possible.

My second thought was to create a webpage that would search that site and get all the required data, then provide a "Download data to Excel" option. Are these ideas possible and how would I best go about doing them? Is there a better way? Thanks!

This would be easier to answer if we know what languages you're familiar with.

Assuming windows this can be done using jscript or vbscript on WSH using WinHttpRequest, excel may be accessed via ActiveX. If you need a UI i would suggest HTA.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM