ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Copy Macros and VB code from one workbook to another (https://www.excelbanter.com/excel-programming/284188-copy-macros-vbulletin-code-one-workbook-another.html)

Dawn[_2_]

Copy Macros and VB code from one workbook to another
 
I have copied a production workbook to a test environment
and created some macros and vb code to go along with the
workbook. From the time I copied the book to test a lot of
changes have taken place to the production book. How do I
copy or move the macros and vb code from the test version
to the production version?



John Wilson

Copy Macros and VB code from one workbook to another
 
Dawn,

For help on doing this in VBA, take a look he
http://www.cpearson.com/excel/vbe.htm

Manually, you can open the VBA editor and export each
of the modules from the "test" version and import them
to the "production" version.
Easier way is to open both workbooks and from the VBA
editor and just drag and drop modules and userforms from
one to the other.

John

"Dawn" wrote in message
...
I have copied a production workbook to a test environment
and created some macros and vb code to go along with the
workbook. From the time I copied the book to test a lot of
changes have taken place to the production book. How do I
copy or move the macros and vb code from the test version
to the production version?






All times are GMT +1. The time now is 04:09 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com