2

Overview

I'm trying to add a mapped Sharepoint Library to Trusted Location in Office for macro enabled files so end users don't have to select "Enable Macros" every time they launch the file. Additionally, many of my companies macro enabled files have code that runs on open to protect the workbook from editing.

Details

I've mapped Sharepoint (https://companydomain.sharepoint.com/Shared Documents/) as a drive letter in windows 10. This works flawlessly, but for macro enabled office files I get the Security Warning and have to enable macros every time. In that past to keep this form happening I've simply added the network share as a "Trusted Location" in the appropriate office application through the following steps

  1. Office Settings
  2. Options
  3. Trust Center
  4. Trust Center Settings
  5. Trusted locations
  6. Check "Add locations on my network"
  7. Browse to folder and click ok!

This has works for the shard drive on our server, but when I try this for the Sharepoint mapped Drive...it changes the file pat the a the url above. However, I still get the warning when I open the macro enabled file!

After doing some investigating I realized that the actual file path for the file is more like the following:

\\companydomain\sharepoint.com@SSL\DAVWWWRoot\Shared Documents\

When I try to add it to trusted locations, however, I get the following error: "The path you have entered cannot be used as a trusted location for security reasons".

After doing some more digging I was able to add the path through a registry edit of the location where these paths are stored, but that still does not work...the path is grayed out in "Trusted Locations" and macro enabled files opened from that location still have the security warning.

I also tried adding just the drive letter and the drive letter and sub folder with equal success.

Known solutions/workarounds

  1. Add Sharepoint as a synced folder instead of a mapped network drive.
    • I know this will work because this is how we do OneDrive for Business, however, the concern/fear is that adding our Sharepoint this way will eat up the disk space on the local PC.
  2. Digitally signing the vba projects with a self cert from the company and adding the company as a Trusted Publisher in Office.

    • I know this works because I've done it...the biggest down side is every time a code is edited it has to be re-signed. Also some of our macro enabled documents create other documents from templates that also are macro enabled and I'm pretty sure the the certification doesn't pass from parent to child. It would be impractical for me to digitally sign all the new created documents one by one assuming I even knew when they were created.

I can't be the first person to attempt/want this and am hoping that someone out there has a solution.

0

Try adding the target URL (domain part only) to Trusted Sites under Internet Options (part of the Control Panel).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.