May 16 2022 11:02 AM
I'm trying to make a file that acts as a shortcut to another file in a SharePoint document library on both the web version and the file explorer.
I have tried the following:
LNK Files
I can create a Windows shortcut (LNK file) in the synced folder (in my file explorer), but it does not work for the web version nor other people’s computers (the path is different).
URL Files
I have tried to make a URL file (**New** > **Link**). It works in the web version, but not quite well in the file explorer. For example, when I click on a link to a Word document in the file explorer, the file opens in the web version of Word (on SharePoint) instead of the local program.
ASPX "Link to a Document"
I have tried the “Link to a Document” content type (https://www.spguides.com/link-to-a-document-sharepoint-document-library/), but it only works in the web version.
Solution
Is there a solution that will work for both the web version and the file explorer?
May 16 2022 12:18 PM
May 17 2022 05:41 AM
@PamDeGraffenreid
This is my situation:
I have a synced/shared folder with the path
C:/Users/myuser/Example Tenant/Example Site - Documents
In that folder, I have a file with the path
C:/Users/myuser/Example Tenant/Example Site - Documents/Target File.docx
I do the following:
1. Right-click the file
2. Select "Create shortcut"
3. Rename the shortcut to "Shortcut to Target File"
The path of the shortcut-file is now
C:/Users/myuser/Example Tenant/Example Site - Documents/Shortcut to Target File.lnk
This shortcut points to
C:/Users/myuser/Example Tenant/Example Site - Documents/Target File.docx
Another user is syncing the same site to their computer.
In their file explorer, they see a shortcut-file
C:/Users/otheruser/Example Tenant/Example Site - Documents/Shortcut to Target File.lnk
They right click the shortcut file to inspect it's properties.
The shortcut points to
C:/Users/myuser/Example Tenant/Example Site - Documents/Target File.docx
When the other user double-clicks that shortcut, nothing happens.
This is because they do not have a file with the path
C:/Users/myuser/Example Tenant/Example Site - Documents/Target File.docx
However, the other user does have a file with the path
C:/Users/otheruser/Example Tenant/Example Site - Documents/Target File.docx
Does this make sense?
May 17 2022 12:07 PM
@a531 I see. Two options:
Those links should work for anyone that has access because it will point directly to the document in the browser.
Mar 29 2023 03:05 AM
Apr 11 2023 03:55 AM
I tried replacing c:/users/myuser with %HOMEPATH% which seems to do the trick....
Apr 11 2023 06:28 AM
I think that is the best option for now, although the site needs to be synced to the same path following that homepath variable. Sometimes, users will sync a single folder from a site.
Jan 04 2024 07:50 AM
thank you, the %HOMEPATH% worked for me and allowing others to use the shortcuts is fantastic.
Feb 08 2024 08:27 AM
Feb 08 2024 08:44 AM
change "C:\Users\%HOMEPATH%\etc\etc..."
to "%HOMEPATH%\etc\etc..."
but for some reason i cannot get my shortcuts to work for everyone. initially one person used it but then it stopped and when i looked at it the shortcut was changed back to the address without %homepath%. I wonder if it had to do with Win10 users trying to use it.