Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Greetings !
In my workbook, I have a 'change event' macro (started with the line "Private Sub Worksheet_Change(ByVal Target as Range"). After much work, this macro runs just fine. My problem is that a totally separate macro, which I call "Clear_Glass_Data", somehow calls the 'change event' macro into play. I'm guessing that this happens because the "Clear_Glass_Data" changes many cell values from TRUE to FALSE, therefore causing an "event" change. Is there a way of isolating my "Clear_Glass_Data" macro so that it can't see or call any other macros?? Thanks for your help, Jay N. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Jay, Events can be disabled in excel by use of Application.EnableEvents You must ALWAYS remember to enable events when you have finished. I normally do it like this ... Application.EnableEvents = False Your update code Application.EnableEvents = True and dont forget to put in an error trap that has Application.EnableEvents = True included. I would imagine that this code would be placed in your Clear_Glass_Dat macro -- Kiera Born ignorant and still perfecting the ar ----------------------------------------------------------------------- Kieran's Profile: http://www.excelforum.com/member.php...nfo&userid=124 View this thread: http://www.excelforum.com/showthread.php?threadid=27144 |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Kieran,
Thanks so much for your help! Your suggestion works perfectly, and I have learned something new. Jay "Kieran" wrote in message ... Jay, Events can be disabled in excel by use of Application.EnableEvents You must ALWAYS remember to enable events when you have finished. I normally do it like this ... Application.EnableEvents = False Your update code Application.EnableEvents = True and dont forget to put in an error trap that has Application.EnableEvents = True included. I would imagine that this code would be placed in your Clear_Glass_Data macro. -- Kieran Born ignorant and still perfecting the art ------------------------------------------------------------------------ Kieran's Profile: http://www.excelforum.com/member.php...fo&userid=1247 View this thread: http://www.excelforum.com/showthread...hreadid=271446 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Phone calls | Excel Discussion (Misc queries) | |||
Calls per Day | Excel Discussion (Misc queries) | |||
Y-Axis Auto-Scale Min Erroneously Set At Zero | Charts and Charting in Excel | |||
XLA calls dll | Excel Programming | |||
VBA Calls | Excel Programming |