LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 280
Default Disable Change Event in Form

The Change event will fire when it fires. You cannot control it directly.
You can ignore it by not having a Change event handler, or you can have a
module-level or global variable in the Change event handler whose value
determines whether or not the code actually does anything. You can set the
value of this variable depending on other events and conditions.


Private Sub Text1_Change()

If mAllowChangeEvent Then
'do stuff
End If

End Sub

Private Sub Text2_Change()

If mIgnoreChangeEvent Then Exit Sub
'do stuff

End Sub

wrote in message
anews.com...
Hi,

I've tried a variety of things including
Application.EnableEvents = False
. . . change textbox . . .
Application.EnableEvents = True
but I have not been able to prevent the
change event from firing.

What am I missing? Is it possible to
stop the Change event from within the
form code?

Thanks,

David




 
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
KeyDown event on form Horatio J. Bilge, Jr. Excel Discussion (Misc queries) 0 October 26th 07 03:30 PM
Disable SelectionChange Event BillCPA Excel Discussion (Misc queries) 2 February 17th 06 06:45 PM
I need to disable to X on a user form cwwolfdog Excel Discussion (Misc queries) 2 March 28th 05 02:33 AM
change event/after update event?? scrabtree23[_2_] Excel Programming 1 October 20th 03 07:09 PM
Disable Worksheet change event Tim[_14_] Excel Programming 4 July 15th 03 01:27 AM


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