VBA & Macro Problems

How to Allow Macros in Excel Files on a Network Drive

Steven ParkerSteven Parker Nov 13, 2026 868 views

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.

How to Allow Macros in Excel Files on a Network Drive
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.
Before you start

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.

Solution 1Recommended

Clear the Trusted Documents cache in Excel

Use this first when Excel continues to treat a previously blocked network workbook as untrusted.

1
Open Trust Center

In Excel, click File > Options > Trust Center, then select Trust Center Settings.

2
Clear trusted document records

Select Trusted Documents in the left pane and click Clear, then click OK to remove cached trust decisions for the network workbook.

Clear the Trusted Documents cache in Excel
Cache may rebuild: After clearing the cache, reopening the workbook may prompt you again to enable content. Use the security warning bar only if you trust the file source.
Free Microsoft Office alternative

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. 1. Download WPS Office: Go to the WPS Office download page and download the free installer for Windows, macOS, or your supported platform.
  2. 2. Open the macro-enabled workbook: Launch WPS Spreadsheets and open the .xlsm or .xls workbook from the network drive or local folder.
  3. 3. Allow macros when prompted: Use the WPS macro security prompt or security settings to enable macros for trusted workbooks.
  4. 4. Keep Excel-compatible formats: Use Save As to keep the file in .xlsm or .xlsx format for Microsoft Excel compatibility.
Opens and saves Excel .xls, .xlsx, and macro-enabled .xlsm workbooksFree and lightweight with a familiar Microsoft Excel-style interfaceBuilt-in macro security controls help you manage VBA workbooksReduces reliance on Microsoft Excel Trusted Location restrictions for everyday macro filesSeamless migration from Microsoft Excel without losing familiar workflows
microsoft office alternative - wps office

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.