dLSoft  barcode & labelling software     

How to Copy Excel macros

from a sample workbook to a new workbook or template.

1. Open Excel Options from the Office icon (Excel 2007) or the File menu (Excel 2010/2013).

2. For Excel 2007 ensure that the checkbox labelled Show Developer tab in the Ribbon is checked. For Excel 2010/2013 select the Customise Ribbon item and ensure that the Developer checkbox is checked.

2. Open bmacs2007.xlsm and using the Options button alongside the security warning ensure that "Allow this content" is selected. For Excel 2010/2013 just push the button labelled “Enable content”

3. Open a new blank workbook or one in which you wish to use the barcode macros.

4. Select the Developer tab above the Ribbon and select the Visual Basic icon.


Copying macros to a new workbook in Excel

5. In the Project section (top left) expand the topics for both the bmacs2007 and the other workbook as shown above.

6. Select BarmacsExcel module in the bmacs2007 section, then, holding down the control key, drag it to the main heading of the other book – VBAProject (Book1) in the sample above. A Modules section will appear in the list under the second workbook.

copying excel macros


7. Now from the File menu choose “Close and Return to Microsoft Excel”; Save your workbook.

The barcode macros are now present in your workbook and ready for use.

Note To help prevent potentially dangerous code from running, we recommend that you return to any of the settings that disable all macros after you finish working with macros.

The new workbook may aslo be saved as a Template using the File - Save As menu and selecting Macro Enabled Template as the file type.

For further information see the product's Help file