Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default Store VBA-Code centrally

Hi!

I have certain instances of Excel-Sheets with VBA code. I update the
code frequently and have to go through all the Excel sheets and copy and
paste the updates.

Is there a way to store the code centrally and have the sheets update
automatically?

Best regards,
Martin
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 22,906
Default Store VBA-Code centrally

If all the sheets are in one workbook and the code is same for each sheet,
place the code in Thisworkbook module.

Private Sub Workbook_SheetChange(ByVal Sh As Object, _
ByVal Target As Range)

your code here

End Sub

If sheets in multiple workbooks see Chip Pearson's site.

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


Gord Dibben MS Excel MVP

On Wed, 19 Aug 2009 14:22:53 +0200, Martin Schneider
wrote:

Hi!

I have certain instances of Excel-Sheets with VBA code. I update the
code frequently and have to go through all the Excel sheets and copy and
paste the updates.

Is there a way to store the code centrally and have the sheets update
automatically?

Best regards,
Martin


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default Store VBA-Code centrally

Gord Dibben schrieb:
If sheets in multiple workbooks see Chip Pearson's site.

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


That's it, I guess :-) Thanks and best regards

Martin
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
Where to store VBA code for executing against xls in email? Diwa Excel Programming 5 August 5th 09 03:40 PM
Store code outside the workbook, is it possible? Mark Stephens Excel Programming 5 June 11th 08 04:54 PM
Code to track changes by row and store Mike Excel Programming 0 July 5th 07 02:56 PM
Store FilePath Inside Code Magnivy Excel Programming 3 August 16th 06 10:08 PM
What method do you use to save/store your developed code? Scott Wagner Excel Programming 5 December 19th 05 03:38 AM


All times are GMT +1. The time now is 06:26 AM.

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

About Us

"It's about Microsoft Excel"