Skip to content

Updating Your Toolkit

Jimm Domingo edited this page Sep 5, 2018 · 2 revisions

Instructions to update your toolkit's project for a new release of this framework project.

  1. Copy in framework files

    Unpack the release's zip file or tarball, and then copy its source files (*.bas, *.cls) into your toolkit's working directory. Your version control software should indicate which framework files have been changed or added in this release.

    Note: additional steps are required if the release contains core changes (described in the section below).

  2. Verify the changes

    Open the Development edition of your toolkit with its macros enabled. Confirm that the toolkit's menu and macros work as expected.

  3. Commit the update

    For example:

     git commit -a -m "Update vba-libs to version 1.2.3"
    

Updating Core Modules

Since core modules are always present in the Development edition of your Excel toolkit, they are NOT imported when that edition is opened with macros enabled. Therefore, if a new release of this add-in framework has revised source files for any of the core modules:

  • ThisWorkbook.cls
  • bootstrap.bas

you need to manually load the changes into your add-in.

Load the update_core module

First, prepare the toolkit for core modifications.

Open the VB editor's Immediate Window so you can view the progress of these steps.

In the upper right of the bootstrap module's window, select the LoadModuleForCoreUpdates macro in the pull-down menu.

Run that macro, which will load the special update_core module.

Run macro in update_core

Double-click the update_core module to open its window. Locate the UpdateCoreModules macro in its pull-down menu.

Run that macro, which will update each core mdoule by reading in its revised source code from its source file.

Unload the update_core module

You need to unload the special module before you can save your add-in. So close the update_core window. Then in the bootstrap window, select the UnloadModuleForCoreUpdates macro.

Run that macro, which will remove the update_core module.

And finally, save your toolkit and restore the original name of its Development edition.