Fix a Macro-Enabled Excel File Blocked After OneDrive Sharing
Question details
The user needs to open a macro-enabled Excel workbook shared through OneDrive without an unexpected security warning.

- Product
- Microsoft Excel and OneDrive
- Device & OS
- not provided
- Scenario
- A user opens a shared macro-enabled workbook and wants to use it in Excel.
- Observed behavior
- A security warning continues to appear after changes to trusted locations and Trust Center settings.
Confirm that the workbook and its macros come from a trusted sender, and check whether you are opening it in a browser or desktop Excel. If the file belongs to an organization, check with your Microsoft 365 administrator before changing security settings.
Open a Downloaded Copy in Desktop Excel
Use this approach to check whether a downloaded workbook is blocked by Windows and open it in the desktop app.
In OneDrive, select the shared workbook and choose Download. Save it to a local folder.
On Windows, right-click the downloaded file in File Explorer and select Properties. On the General tab, select Unblock if it appears, then click Apply and OK.
Open the downloaded file in desktop Excel using File > Open. Check whether the workbook opens and whether the security warning remains.

Use an Approved Trusted Location in Excel
Use this option when your organization permits trusted locations and you trust the workbook and its macros.
Ask Your Microsoft 365 Administrator to Review Policies
Use this approach if the warning persists or the workbook must remain shared for collaboration.
Work With Excel Spreadsheets in WPS Office
WPS Office is a free, lightweight Office alternative with a familiar interface for working with compatible spreadsheets. Its Microsoft Office format support can help you move existing documents into WPS, although it does not change Excel or OneDrive security policies.

Frequently Asked Questions
Why does the workbook still show a warning after I change Trust Center settings?
The file may be marked as downloaded from the internet, or an organization policy may restrict macros or trusted locations. On Windows, check the downloaded file's Properties for an Unblock option, and ask your administrator to review any applicable policies.
Can I run the workbook's macros in Excel for the web?
Excel for the web cannot run VBA macros. Open the workbook in desktop Excel to use supported VBA macros, subject to your security settings and organization policies.
What if there is no Unblock option in file properties?
The file may not have a Windows internet-origin block, or another restriction may apply. Open it in desktop Excel and share the exact warning with your Microsoft 365 administrator.
Will downloading the workbook update the shared OneDrive file?
No. A downloaded copy is separate from the shared file. Ask your administrator how to use the workbook collaboratively while following your organization's macro security policies.




