How to patch a model workbook after upgrading Autory¶
Why?¶
Patching an Autory model workbook is necessary when new features are added to Autory that require updates in the model workbook. It updates the VBA code, tables, named ranges, etc. in the model workbook to ensure compatibility with the latest version of Autory.
When?¶
This is typically done directly after installing a newer version of Autory. However, not all upgrades require this. For more information about Autory upgrades, see the upgrade guide.
Steps¶
-
Open the folder where your model workbook is saved.

-
Open a terminal.
-
Type
autory patch "Autory Model.xlsm"(use the name of your actual file) and hitEnter.
During the patch, a backup is made in the same folder adding a timestamp + '.original' postfix to the original file. The
Autory Model.xlsmfile is now patched and should be compatible with the installed Autory engine.
VBA object model access¶
At the time of writing, most Autory model workbooks contain some VBA code
(to make various buttons and dropdown lists function properly in the workbook).
The autory patch command updates this VBA code to be compatible with the installed Autory version.
To do this, it requires the "Trust access to the VBA project object model" setting in Excel to be enabled.
The autory patch command will attempt to enable this setting automatically.
If it fails, you can enable it manually by following these steps in Excel:
- Click File
- Click Options
- Click Trust Center
- Click Trust Center Settings...
- Click Macro Settings
- Tick "Trust access to the VBA project object model"
- Click OK