View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Bruno Vermeersch Bruno Vermeersch is offline
external usenet poster
 
Posts: 1
Default Macro Copying To Another Workbook??

A macro is written in a "module" of the active workbook.
So, if you close this workbook, you indeed have no longer access to that
macro.

I see 2 solutions (for the moment), even if none of them is quite
users-friendly :
1) you can open the Microsoft Visual Basic, insert a new module in your new
workbook and copy the text of your macro to paste in the new module
2) you can export your module from the original workbook and import it in
your new workbook

As I said, none of them is user-frindly, but at least, you get your macros
copied.

Hope this helps a bit,
Bruno



"countryfan_nt" wrote in
message ...

Friends, Please help me!

I have a workbook with macros in its sheets. When I takeout sheets into
a new workbook and close the orginal workbook. The New workbook does not
have the macros?
Why? And how can I have the macros travel with whatever sheet I create
away from its parent Workbook.

Please help, Thank you very much for your time.


--
countryfan_nt
------------------------------------------------------------------------
countryfan_nt's Profile:

http://www.excelforum.com/member.php...o&userid=11051
View this thread: http://www.excelforum.com/showthread...hreadid=355861