LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default Disable worksheet macros when copying a worksheet in VBA

I am using the worksheet.copy method to copy a worksheet intact. The source worksheet has a few event macros that I would like to disable in the destination worksheet.

I considered just copying the contents of the source to a new worksheet. However, the source worksheet contains some controls I would like to keep in the destination sheet. These controls call to module subroutines outside the worksheet.

I can see two possible solutions, but I do not know how to execute any of them:
1) Disable all worksheet VBA code for the destination worksheet
2) Copy the contents of the source worksheet, and then copy only the buttons I want to use.

Can someone point me to the method or function I can use for either strategy? Thanks, Craig.


Submitted via EggHeadCafe - Software Developer Portal of Choice
..NET Abstract Factory
http://www.eggheadcafe.com/tutorials...t-factory.aspx
 
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
copying worksheet including graphs to new worksheet leif Excel Discussion (Misc queries) 9 March 7th 10 04:03 AM
disable macros in a worksheet Gordon[_2_] Excel Programming 5 September 24th 08 09:30 PM
Looking up a variable in one worksheet and copying information from another column to another worksheet?? Brad Torken Excel Discussion (Misc queries) 2 December 10th 06 06:02 AM
Copying a worksheet witrh protected cells to a new worksheet John Excel Worksheet Functions 2 February 1st 06 02:19 PM
Copying Worksheet triggers Click event of combobox on another worksheet Robert[_20_] Excel Programming 0 January 23rd 04 07:40 PM


All times are GMT +1. The time now is 07:23 AM.

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"