VBA code to contol Form Control checkboxes

Checkboxes are one of the easiest ways to create interaction with users.  Controlling them with VBA makes them more flexible and more useful in Excel applications. Here is a collection of the most common code snippets and settings. Create Check Boxes The following code will create a checkbox Sub CreateCheckBoxes() ‘Create variable Dim chkBox As Read More

Run a macro from a macro (from another workbook)

In VBA, there are several ways to run a macro within a macro, and even run a macro from another workbook.  On forums these methods are used interchangeably depending on the commenter’s personal preferences.  This can lead to confusion for anybody trying to learn VBA.  Depending on the method for running/calling the macro, the syntax Read More

VBA Code to control Excel’s Zoom settings

Excel has zoom settings for worksheets, UserForms and print settings.  Each of these serves different purposes and used at different points, but they can all be controlled by VBA. Worksheet zoom settings The worksheet zoom setting in Excel will always be an integer.  If the value set by VBA contains decimal places it will be Read More