ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Copy a macro (https://www.excelbanter.com/excel-programming/295634-copy-macro.html)

pauluk[_40_]

Copy a macro
 
Hi,

I need to create a macro which will copy another macro to anothe
workbook. How can you go about this

--
Message posted from http://www.ExcelForum.com


Mike Fogleman

Copy a macro
 
This link may give you a starting point:
http://www.j-walk.com/ss/excel/tips/tip61.htm

Mike F
"pauluk " wrote in message
...
Hi,

I need to create a macro which will copy another macro to another
workbook. How can you go about this?


---
Message posted from http://www.ExcelForum.com/




Tom Ogilvy

Copy a macro
 
See Chip Pearson's page on using code to work with code

http://www.cpearson.com/excel/vbe.htm

It doesn't have sample code for exactly what you are asking, I don't
believe, but it has all the basic information you need.

--
Regards,
Tom Ogilvy

"pauluk " wrote in message
...
Hi,

I need to create a macro which will copy another macro to another
workbook. How can you go about this?


---
Message posted from http://www.ExcelForum.com/




Bob Phillips[_6_]

Copy a macro
 
Simplest way is to copy the code to a text file and copy it in the other
workbook with

ActiveWorkbook.VBProject.VBComponents("Module1") _
.CodeModule.AddFromFile "C:\myTEst\volker1.xls"

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"pauluk " wrote in message
...
Hi,

I need to create a macro which will copy another macro to another
workbook. How can you go about this?


---
Message posted from http://www.ExcelForum.com/





All times are GMT +1. The time now is 08:28 AM.

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