Convert a OneDrive path to the local path

FryGirl

Well-known Member
Joined
Nov 11, 2008
Messages
1,368
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

Easy bullets in Excel
If you have a numeric keypad, press Alt+7 on numeric keypad to type a bullet in Excel.
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,223,948
Messages
6,175,579
Members
452,652
Latest member
eduedu

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