How to Allow Macros in Excel Files on a Network Drive
Question details
The user needs to enable VBA macros in an Excel workbook stored on a network drive after Excel blocks the macro because the location is not trusted.

- Product
- Microsoft Excel / WPS Office Spreadsheets
- Device & OS
- not provided
- Scenario
- A workbook containing VBA macros is opened from a network drive, and the user needs the macros to run.
- Observed behavior
- Excel blocks macros, and the network drive cannot be added to Trusted Locations through normal Excel settings.
Close the Excel workbook before changing file properties or Trust Center settings, and confirm you have permission to open and modify files in the network location.
Clear the Trusted Documents cache in Excel
Use this first when Excel continues to treat a previously blocked network workbook as untrusted.
In Excel, click File > Options > Trust Center, then select Trust Center Settings.
Select Trusted Documents in the left pane and click Clear, then click OK to remove cached trust decisions for the network workbook.

Unblock the workbook through Windows file properties
Use this when the file has a Windows security block or was copied from another computer or the internet.
Ask your administrator to approve the network location
Use this when local Excel and Windows settings do not resolve the block because organization security policies control network macro locations.
Use WPS Office Spreadsheets as a Free Excel Alternative
If Excel Trusted Location restrictions on network drives block your macro workbooks, WPS Office Spreadsheets offers a free, lightweight alternative with a familiar ribbon interface, strong Excel format compatibility, and macro support for smoother migration from Microsoft Excel.
- 1. Download WPS Office: Go to the WPS Office download page and download the free installer for Windows, macOS, or your supported platform.
- 2. Open the macro-enabled workbook: Launch WPS Spreadsheets and open the .xlsm or .xls workbook from the network drive or local folder.
- 3. Allow macros when prompted: Use the WPS macro security prompt or security settings to enable macros for trusted workbooks.
- 4. Keep Excel-compatible formats: Use Save As to keep the file in .xlsm or .xlsx format for Microsoft Excel compatibility.

Frequently Asked Questions
Why does Excel block macros when I open a workbook from a network drive?
Excel treats network locations as less trusted than local folders. It blocks VBA and other macros unless the file is unblocked, the document is trusted, or the network path is added to Trusted Locations.
How do I clear the Trusted Documents cache in Excel?
Open Excel, go to File > Options > Trust Center > Trust Center Settings > Trusted Documents, then click Clear and OK.
How do I unblock an Excel file that came from a network drive or the internet?
Close the file, right-click it in File Explorer, select Properties, open the General tab, check Unblock if available, and click Apply and OK.
Can I add a network location to Excel Trusted Locations myself?
Yes, if your organization allows it. In Trust Center > Trusted Locations, enable Allow Trusted Locations on my network, then add the network path. If the option is disabled, contact your administrator.
Does WPS Office support Excel macro files?
WPS Office Spreadsheets can open macro-enabled Excel workbooks and provides macro security settings, making it a lightweight alternative for working with .xlsm files.




