Pull the HTML from multiple sites using VBA

samcd87

New Member
Joined
Apr 8, 2022
Messages
14
Office Version
  1. 365
Platform
  1. Windows
  2. Web
I have column A full of lots of URLs and they each return a basic string of text.

Two examples:

I am looking for a piece of VBA that would look at the first URL and pull the data, paste it in to column B and then move to the second URL and pull the schedule and so on until they have all been pulled.
Thanks in advance for any advice.
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
Well this is one of those occasions where you don't even need VBA or Power Query to do this - you can do it with a formula on the worksheet!
If the URL is in A1, and you want the text to output to B1, then put the following into B1:

Excel Formula:
=WEBSERVICE(A1)

and then it's easy enough to copy that formula down to the rest of the cells in the column. Let me know how you get on.
 
Upvote 0

Forum statistics

Threads
1,216,104
Messages
6,128,856
Members
449,472
Latest member
ebc9

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top