Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
I have 2 combo boxes on the same sheet and both have Combobox_Change() event
code associated with them. This code resides in the sheet object (same sheet) and both macros call other routines in a module in this same spreadsheet file. When one of these events fires, I want to inhibit the other from firing while the first's code is executing. I've tried using Application.EnableEvents = False, but it's just ignored. Does anyone know why this would be? Thanks, Will |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Changes to these controls aren't affected by application.enableevents settings
(as you've seen). But you could do the same sort of thing... Dim BlkProc as boolean private sub combobox1_change() if blkproc = true then exit sub 'rest of your code here end sub private sub combobox2_change() if blkproc = true then exit sub 'rest of your code here blkproc = true 'some code that would cause combobox1_change to fire blkproc = false end sub roadkill wrote: I have 2 combo boxes on the same sheet and both have Combobox_Change() event code associated with them. This code resides in the sheet object (same sheet) and both macros call other routines in a module in this same spreadsheet file. When one of these events fires, I want to inhibit the other from firing while the first's code is executing. I've tried using Application.EnableEvents = False, but it's just ignored. Does anyone know why this would be? Thanks, Will -- Dave Peterson |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Thanks - that worked just fine. What events DOES the EnableEvents setting
affect? "Dave Peterson" wrote: Changes to these controls aren't affected by application.enableevents settings (as you've seen). But you could do the same sort of thing... Dim BlkProc as boolean private sub combobox1_change() if blkproc = true then exit sub 'rest of your code here end sub private sub combobox2_change() if blkproc = true then exit sub 'rest of your code here blkproc = true 'some code that would cause combobox1_change to fire blkproc = false end sub roadkill wrote: I have 2 combo boxes on the same sheet and both have Combobox_Change() event code associated with them. This code resides in the sheet object (same sheet) and both macros call other routines in a module in this same spreadsheet file. When one of these events fires, I want to inhibit the other from firing while the first's code is executing. I've tried using Application.EnableEvents = False, but it's just ignored. Does anyone know why this would be? Thanks, Will -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Disable Query Refresh warning dialog box in Excel 2003 | Excel Discussion (Misc queries) | |||
Disable Customize toolber tabs | Excel Discussion (Misc queries) | |||
disable customize option when right click on menu bar | Excel Discussion (Misc queries) | |||
Running Excel events even in edit mode.... | Excel Discussion (Misc queries) | |||
Outlook 2003 calendar events into Excel 2003? | Excel Discussion (Misc queries) |