VBA & Macro Problems

Fix “File Not Found” When Opening VBA Code in Microsoft Office

Phi Hung VoPhi Hung Vo Nov 20, 2026 870 views

Question details

The user needs to open and edit VBA modules without a “File not found” error.

Fix “File Not Found” When Opening VBA Code in Microsoft Office
Product
Microsoft Office VBA editor in Access, Excel, and Word
Device & OS
Windows
Scenario
Opening VBA code in multiple Office applications.
Observed behavior
The VBA editor reports “File not found” across Access, Excel, and Word.
Before you start

Close all Office applications before starting the repair. Make sure you have an internet connection available if Online Repair is needed.

Solution 1Recommended

Repair Microsoft Office and retest the VBA editor

Use Office Repair when the error appears in multiple Office applications, suggesting an installation problem rather than a single file issue.

1
Find your Office installation

Open Windows Settings > Apps > Installed apps, or Apps & features on Windows 10. Find Microsoft Office or Microsoft 365 in the list.

2
Start Quick Repair

Select the Office entry and choose Modify or Change, then select Quick Repair and follow the prompts.

3
Run Online Repair if needed

Reopen an affected Office app and try opening its VBA code. If the error remains, return to the Office entry in Settings, choose Modify or Change, and select Online Repair.

4
Restart and test

After repair finishes, restart Windows. Open Access, Excel, or Word and try opening the affected VBA module again.

Repair Microsoft Office and retest the VBA editor
Online Repair resolved the reported case: In the reported case, Quick Repair did not resolve the error, but Online Repair restored VBA editing.
Free Microsoft Office alternative

Work with Office documents in WPS Office

WPS Office is a free, lightweight alternative with a familiar interface for working with Office documents and spreadsheets. Open compatible files to make migration easier; it does not repair Microsoft Office or its VBA editor.

Free, lightweight tools for everyday document and spreadsheet workCompatible with Microsoft Word and Excel formats, including DOCX and XLSXFamiliar editing interface for an easier transition from OfficeOpen and edit spreadsheet content without relying on the Microsoft Office VBA editor
microsoft office alternative - wps office

Frequently Asked Questions

Why does the error appear in Access, Excel, and Word?

An error across several Office apps can indicate a damaged Office installation rather than a problem with one document or database. Try repairing Office through Windows Settings > Apps.

What if Quick Repair does not fix the VBA error?

Return to the Office installation under Settings > Apps, select Modify or Change, and run Online Repair. Restart Windows and test the VBA editor again.

Does Online Repair require an internet connection?

Yes. Connect to the internet before selecting Online Repair in the Office repair dialog.

Can WPS Office repair the Microsoft Office VBA editor?

No. Use Microsoft Office Repair to address the VBA editor error. WPS Office is an alternative for working with compatible documents and spreadsheets, not a repair tool for Office.