Power Query- Access one drive files

sanket_sk

Board Regular
Joined
Dec 27, 2016
Messages
67
Office Version
  1. 365
Platform
  1. Windows
Hi All,

I have small doubt in Power query.

I have files stored at One drive, files are getting updated every week.

Is there any way by which I can connect and update these file through power query (Desktop Excel File).

Sanket
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK

sandy666

Banned - Rules violations
Joined
Oct 24, 2015
Messages
7,497
a) You want to update files on OneDrive from local file
or
b) You want to update local file from OneDrive
 

sanket_sk

Board Regular
Joined
Dec 27, 2016
Messages
67
Office Version
  1. 365
Platform
  1. Windows
I want to keep all base files at one drive (Online) and keep updating power query which is available at local excel file.
 

sanket_sk

Board Regular
Joined
Dec 27, 2016
Messages
67
Office Version
  1. 365
Platform
  1. Windows

ADVERTISEMENT

B
 

sandy666

Banned - Rules violations
Joined
Oct 24, 2015
Messages
7,497
so create query in your local file to the file (files) on OneDrive (usually files on OneDrive online are reproduced in your local OneDrive folder)
 

sanket_sk

Board Regular
Joined
Dec 27, 2016
Messages
67
Office Version
  1. 365
Platform
  1. Windows

ADVERTISEMENT

Could you please share steps to perform this activity
 

sandy666

Banned - Rules violations
Joined
Oct 24, 2015
Messages
7,497
Data tab - New Query - From File - From Worksheet (for single file)
if you want data from another file do the same for another file
or
Data tab - New Query - From Other Sources - From Web (you'll need url to the file)
 

jrg24

New Member
Joined
Aug 6, 2010
Messages
49
I assume you can access the Onedrive source file from windows explorer? If so, create your query by accessing the local file (get data >> from file, etc.) After your query is created, replace the top line with the following:

Rich (BB code):
Source = Excel.Workbook(Web.Contents("File URL"), null, true),

To get the source URL, open the file on your computer. Go to file >> info At the top you will see a path that says something like "One Drive >>folder >> folder". You should see an option that says "copy path (if you dont see that, right click and you should get the option.) Paste the path into where it says File URL above. The URL must be in quotes. At the end of the URL you will see "?web=1" after the .xlsx. You need to delete this from the URL.
 

Watch MrExcel Video

Forum statistics

Threads
1,133,427
Messages
5,658,733
Members
418,467
Latest member
sc356448

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
Top