Convert a OneDrive path to the local path

FryGirl

Well-known Member
Joined
Nov 11, 2008
Messages
1,364
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
I use to be able to use application.path, but not with OneDrive. It seems to have thrown a wrench in that process. Below is what I get for where the file is on OneDrive, but the second line is the path copied from the folder on my hard drive. How can I convert the top line to the bottom line?

C:\Users\Brenda.Fry\OneDrive - military\Brenda_Fry_mil\Documents\Desktop\Files\Log\Measurement\
C:\Users\Brenda.Fry\OneDrive - military\Desktop\Files\Log\Measurement

This is the link that made line #1. Post #4 is what I used.


When I tested this at home it worked fine, but the way our office must configure OneDrive has introduced something different I don't know how to fix.
 

Excel Facts

Waterfall charts in Excel?
Office 365 customers have access to Waterfall charts since late 2016. They were added to Excel 2019.
Not being a member of that forum, I can't see any posted code solutions so forgive me if I miss the mark here. You didn't say whether or not Sharepoint is involved at work or not. If it is, you probably need the UNC path of the SP server, which starts with \\. So like \\SharepointServerName\RootFolderName\TopFolderName1\...
If you have a drive letter mapped to the SP server, you can see its path by using Windows File Explorer.
 
Upvote 0
Great Micron. Thank you for the help. I'll look into this more when I return to work on Monday, and yes, I do believe the SharePoint is involved.
 
Upvote 0

Forum statistics

Threads
1,215,071
Messages
6,122,963
Members
449,094
Latest member
Anshu121

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