Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 44
Default How to attach a code module to a group of workbooks?

Is there a way to use a common code module and attach it to more than one
workbook? If so, how do you make its procedures and funtions available to
the workbook and the worksheets in the workbooks where it is attached.

Thanks,

Keith


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default How to attach a code module to a group of workbooks?

No, but you code put the code in an add-in. Then you run the code in the
add-in like so

Application.Run "myaddin.xla"mymacro"

--
HTH

Bob Phillips

"keithb" wrote in message
...
Is there a way to use a common code module and attach it to more than one
workbook? If so, how do you make its procedures and funtions available to
the workbook and the worksheets in the workbooks where it is attached.

Thanks,

Keith




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default How to attach a code module to a group of workbooks?


Hi Not sure if this is what you want but

If you put all of your code into one workbook and then save it on the
save as menu select xla rather than an xls and save it as a .xla

This will save it as and excel add-on.

Then this add-on should load with excel everytime. You can the call the
methods from and workbook and even have custom menus that call menus. On
the menus just type the method name mymethod() or call it in code
Call mymethod()

I have my own set of functions that i use as well as the excel standard
ones.

Hope This Helps

:)


--
Nigel_hough
------------------------------------------------------------------------
Nigel_hough's Profile: http://www.excelforum.com/member.php...o&userid=20623
View this thread: http://www.excelforum.com/showthread...hreadid=394266

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Attach code MAX Excel Worksheet Functions 5 March 16th 09 11:11 PM
code in module A to not execute a Worksheet_SelectionChange sub of another module Jack Sons Excel Discussion (Misc queries) 4 December 11th 05 11:52 PM
copying vba code to a standard code module 1vagrowr Excel Discussion (Misc queries) 2 November 23rd 05 04:00 PM
Create a newworksheet with VBA code and put VBA code in the new worksheet module ceshelman Excel Programming 4 June 15th 05 04:37 PM
How do I properly attach vba code to a workbook DrKilbert New Users to Excel 2 March 24th 05 10:39 PM


All times are GMT +1. The time now is 12:36 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"