PQ from web - get URL from a cell that dynamically changes in a template? Any videos?

AustSportingPix

New Member
Joined
Oct 5, 2020
Messages
42
Office Version
  1. 365
Platform
  1. Windows
  2. MacOS
  3. Mobile
I have a template that I use every day.
I rip all my data from google sheets which using import html get its data from 4 or 5 sources.
I have google sheets set up that by entering the date & track everything fetches.

I add the google sheet id to my excel template and get from web.


I’ll love to be able to just copy that Google sheet id into my template and hit refresh and all my data update.
I just can’t find any how to videos on “from web”.

I know bill made one that was for weather and for a heap of days. I’m looking for a single sheet.

There was one a couple of years ago that I now can’t find.

Any idea on where I could find a step by step video?
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.
While this is not an exact means for your specific issue, it will demonstrate how to set up a parameter query that you should be able to adapt.

 
Upvote 0
While this is not an exact means for your specific issue, it will demonstrate how to set up a parameter query that you should be able to adapt.

That’s sort of it.

So imagine if cell L2 has a single item in a table with a URL.

If I update that cell and hit refresh PQ goes out and gets the new info.

I know it can be done with files, but I’ve only ever seen one video and I can’t find it.
 
Upvote 0
That’s sort of it.

So imagine if cell L2 has a single item in a table with a URL.

If I update that cell and hit refresh PQ goes out and gets the new info.

I know it can be done with files, but I’ve only ever seen one video and I can’t find it.
It works exactly as you need.
Book1
ABCDE
1Base URL: https://www.mypivots.com/market-holidays/united-states/DateHoliday
2Year: 202212/31/2021New Year's Day
3Calendar URL: https://www.mypivots.com/market-holidays/united-states/202201/17/2022Martin Luther King Day
402/21/2022President's Day
504/15/2022Good Friday
605/30/2022Memorial Day
707/04/2022Independence Day
809/05/2022Labor Day
911/24/2022Thanksgiving Day
1012/26/2022Christmas Day
Sheet2
Cell Formulas
RangeFormula
B3B3=B1&B2
Cells with Data Validation
CellAllowCriteria
B2List2020, 2021, 2022, 2023, 2024

Cell B3 is the named range CalendarURL, is built using the Drop Down in B2, and brought into PQ without it having to be converted to an Excel Table:
Power Query:
let
    Source = Excel.CurrentWorkbook(){[Name="CalendarURL"]}[Content],
    Column1 = Source{0}[Column1]
in
    Column1
That could have been done in one line, but this was generated by using Drill Down on the Source. The resulting table is generated here:
Power Query:
let
    Source = Web.Page(Web.Contents(CalendarURL)),
    Data0 = Source{0}[Data],
    ChangedType = Table.TransformColumnTypes(Data0,{{"Date", type date}})
in
    ChangedType
Note that the URL is the variable created by the first query which is named CalendarURL.
 
Upvote 0
Thanks guys

I couldn’t work it out, but found a video and it worked.
Wasn’t for a URL, but gave it a try and bang, it worked.

Now I might be able to sack google sheets
 
Upvote 0

Forum statistics

Threads
1,216,149
Messages
6,129,149
Members
449,488
Latest member
qh017

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