Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Deactivating all events in ThisWorkbook

Hi,

Is there a code that can deactivating all events contained in the
ThisWorkbook hiddensheet?

Thanks.


  #2   Report Post  
Posted to microsoft.public.excel.programming
JMB JMB is offline
external usenet poster
 
Posts: 2,062
Default Deactivating all events in ThisWorkbook

Try this:

Application.EnableEvents = False

"Gwen" wrote:

Hi,

Is there a code that can deactivating all events contained in the
ThisWorkbook hiddensheet?

Thanks.



  #3   Report Post  
Posted to microsoft.public.excel.programming
GB GB is offline
external usenet poster
 
Posts: 230
Default Deactivating all events in ThisWorkbook

True that this will disable events for the hidden sheet, but it will also
disable events for every sheet. So, if you don't want events to occur on the
hidden sheet, then prior to causing something that would start an event on
the hidden sheet, turn off events, then turn them back on once you are "done"
working on the hidden sheet, however, if the hidden sheet links to other
sheets, then you may run into other problems.

Then again, if there are particular events that you want to be able to
perform on the hidden sheet for given changes, then you can capture which
cell(s) have changed, and disable the particular event. (I think... I'm
wrapping myself around an axle thinking about this one.)
Good luck. :)

"JMB" wrote:

Try this:

Application.EnableEvents = False

"Gwen" wrote:

Hi,

Is there a code that can deactivating all events contained in the
ThisWorkbook hiddensheet?

Thanks.



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 233
Default Deactivating all events in ThisWorkbook

There are just 3 solutions:

temporarerly disable all events. and turn them on when youre done.
Create a global varaible which is inspected by all concerned events
that you can set to TRUE to let all those events know they should exit
ASAP instead of running
Create a Class module to sink the events of the worksheet in, then you
can disconnect the events by destroying the class variable, and
reconnect by creating it again this is the most pretty, but you need to
know how to handle class modules.

DM Unseen

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
Deactivating an Excel Warning Bishop Excel Discussion (Misc queries) 1 May 29th 09 05:48 AM
Deactivating auto macros Jac Tremblay[_3_] Excel Programming 6 July 13th 07 04:00 PM
Deactivating an embedded chart TheRobsterUK Excel Discussion (Misc queries) 0 October 3rd 05 01:30 AM
Copying ThisWorkBook Events mark_1969 Excel Programming 3 December 10th 04 04:04 AM
Deactivating worksheets Keri[_2_] Excel Programming 3 August 31st 04 04:50 PM


All times are GMT +1. The time now is 12:22 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"