How to enable Excel macro files on our shared OneDrive?

MT Kulmala 20 Mainepisteet
2026-04-01T06:25:16.69+00:00

Hiyall,

QUESTION: As in the title.

EARLIER SITUATION, WHEN EVERYTHING WORKED OK

We have a small office with a shared OneDrive. When we were using Win10 computers (without linking to MS account), all Excel files with macros were working fine for every user. Situation as intended: we don't use nor trust outsider macro files, we trust only our own.

SITUATION NOW, WHEN EVERYTHING STOPPED WORKING

After changing to Win11 computers (with linked MS accounts), the Excel files with macros stayed available only to the person who created the file. Any other user, even if they are marked as an editor in the file, cannot use the Excel files with macros.

Now the person who is marked as a creator has to run the macro for others and then save with another name. No, we will not start making copies of macro files for every single user as a creator. That kills the whole point of shared files.

Please note that we didn't change anything in the existing network or share settings. Only thing changed are the computers and linked MS accounts.

TRUSTED LOCATIONS ALREADY ADDED

I've added OneDrive to Trusted Locations in Excel Options. They are both in format onedrive . live . com and in c:/ users/ username/ OneDrive. I've even added individual directories there, but to no avail.

ALREADY TRIED TO UNSTUPIDIFY MYSELF

MS first suggestion is to ask admin. I am the unofficial admin myself, so it's kinda hilarious. Maybe there is an easy fix for this, but the default MS help pages aren't showing this very easily. The default help (invoked from Excel [EDITED] red SECURITY RISK box on top of the spreadsheet) refers to web files only. I have searched the online help and these forums, and I've even asked CoPilot (no help, no surprise). I admit the problem could be between the seat and the keyboard - but that'll be judged after a solution is found :)

Thanks in advance!

Microsoft 365 ja Office | Excel | Muu | Windows
0 kommenttia Ei kommentteja

Kysymyksen esittäjä on hyväksynyt vastauksen
Kai-H 28,235 Mainepisteet Microsoftin ulkoinen henkilöstö Valvoja
2026-04-01T10:59:58.5466667+00:00

(Please note that this is Finnish Q&A Forum, any threads should be posted in Finnish. However, I will still provide an answer in English based on your initial response.)

Hi, MT Kulmala

This usually happens because Windows/Office now treats shared OneDrive files as coming from an untrusted internet or network location, so Excel blocks macros by default. Trusted Locations alone may not be enough unless the file is opened from the right path and Excel is allowed to trust network documents.

Here are some suggestions you can try:

In Excel, add the synced local OneDrive folder as a Trusted Location, not just the web link.

In Trust Center > Trusted Locations, turn on Allow Trusted Locations on my network.

In Trust Center > Trusted Documents, turn on Allow documents on a network to be trusted, then reopen the file and choose Enable Content/Trusted Document.

If you want a cleaner office-wide fix, it is recommended that you digitally sign the VBA project and use Disable VBA macros except digitally signed macros.

Thank you for your patience in reading, I hope this information has been helpful to you. 


If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment."    

Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread. 

Onko tästä vastauksesta hyötyä?

1 henkilö piti tätä vastausta hyödyllisenä.

0 lisävastausta

Lajitteluperuste: Hyödyllisin

Vastauksesi

Kysymyksen tekijä voi merkitä vastauksia hyväksytyiksi ja moderaattorit suositelluiksi, mikä auttaa käyttäjiä tietämään, että vastaus on ratkaissut tekijän ongelman.