Fix Missing Reference Error in Olcalndr Word Template
Question details
The user needs to resolve a VBA compile error preventing the Olcalndr.dot calendar template from functioning properly.

- Product
- Microsoft Word
- Device & OS
- not provided
- Scenario
- Opening or running macros within the Olcalndr.dot calendar template in Microsoft 365.
- Observed behavior
- The template fails to execute properly, displaying a VBA prompt that reads: "Compile error: Can't find project or library."
Ensure you have the Developer tab enabled in your Word ribbon, as you will need access to the Visual Basic for Applications (VBA) Editor to fix this issue.
Resolve Missing Library References in the VBA Editor
Identify and remove or update broken references in the VBA editor that are causing the compile error.
This error typically occurs when the macro code points to a file or library that does not exist on your current machine or is incompatible with your version of Microsoft 365.
Open the Olcalndr.dot template in Word. Press 'Alt + F11' on your keyboard to open the Visual Basic Editor.
In the top menu bar of the VBA Editor, click on 'Tools' and select 'References' from the dropdown menu.
Scroll through the list of Available References and look for any checked items that begin with 'MISSING:'.
Uncheck the box next to the missing reference if the macro does not strictly require it. Alternatively, click 'Browse' to locate the correct missing library file on your computer, then click 'OK'.
Go to 'Run' > 'Run Sub/UserForm' or press F5 to test the macro and confirm the error is resolved.
Save as a Macro-Enabled Template (.dotm) and Check Security
Convert the older .dot template to the modern .dotm format and ensure your macro security settings allow the code to run safely.
Experience Seamless Document Editing with WPS Office
If you are struggling with legacy VBA macro errors and compatibility issues in Microsoft 365, try WPS Office. It provides a highly compatible, fast, and feature-rich environment for your documents without the steep learning curve.
- 1. Download WPS Office: Visit the official WPS website and download the free WPS Office suite for your operating system.
- 2. Install the Application: Run the installer and follow the quick on-screen instructions to set up the software.
- 3. Open Your Templates: Launch WPS Writer and seamlessly open your existing Word documents or browse the extensive free template gallery.

Frequently Asked Questions
What causes the 'Can't find project or library' error in Word?
This error is triggered when a VBA macro attempts to use a code library or object model that is not installed, has been relocated, or belongs to a different version of Microsoft Office than the one currently running.
Are old .dot templates still supported in Microsoft 365?
Yes, Microsoft 365 can open legacy .dot templates using Compatibility Mode. However, for enhanced stability, security, and feature support, it is highly recommended to upgrade and save them as modern macro-enabled templates (.dotm).
Is it safe to simply uncheck a missing reference in the VBA editor?
Yes, unchecking a missing reference is completely safe and often resolves the compile error. If the specific macro you are running does not actually rely on that missing library, the code will compile and execute normally.




