There are 2 file types use the .XLM file extension:
1. Excel Macro
Contains macros used for automating processes in Microsoft Excel; may be preinstalled with Excel or created by the user; can be recorded by selecting Tools→Macro→Record New Macro...; when creating the macro, a keyboard shortcut can be assigned to run the macro.
Updated: September 20, 2006
2. Microsoft Excel Macro
An XLM file contains one or more macros used for automating processes in Microsoft Excel, a spreadsheet application. It is a script used to perform complex or repetitive Excel functions, such as inserting data in cells or formatting charts.
Microsoft introduced XLM files in 1992 with the release of Excel 4.0. The files were commonly used by Excel users until the late-2000s, when Microsoft released Excel 2007. Excel 2007 enabled users to save macros with spreadsheets and save those spreadsheets as .XLSM or .XLTM files.
While XLM files are not as common as they once were, you may still encounter an XLM file that was packaged with an older version of Excel or created by a user. To create an XLM file in Excel 4.0 to 2003, select. When creating the macro, you can assign a keyboard shortcut to run the macro.
NOTE: To view or create a macro in Excel 365, select the "View" tab, then click "Macros."
You can open XLM files with Microsoft Excel in Windows and macOS. However, Microsoft encourages you to migrate the XLM macro to a later version of Microsoft Visual Basic for Applications (VBA).
If you encounter a "security setting" error message in Excel when trying to open an XLM file, you need to change the macro settings in the application to run the macro. To do this, follow these steps:
- Select and click
- Select , and click "Enable all macros (not recommended; potentially dangerous code can run)"
- Select and choose "Excel 4 Macrosheets and Add-in files" under the "File Type" category (verify that the "Open" checkbox is checked
- Choose "Open selected file types in Protected View and allow editing" under "Open behavior for selected file types" and click twice.
XLM files may be used to distribute and execute malware attacks on victims' computers. To protect against malicious attacks, never double-click an unknown XLM file. Verify the legitimacy of the source of the XLM file before attempting to run the macro in Excel.
Updated: August 15, 2020