ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Run-time error '424' in VBA event handler on XL shutdown (https://www.excelbanter.com/excel-programming/328771-run-time-error-424-vba-event-handler-xl-shutdown.html)

Mike Jones

Run-time error '424' in VBA event handler on XL shutdown
 
This is getting aggravating! I have several combobox change event handlers.
They work fine most of the time. But at shutdown, for some reason these
event handlers are firing (which is odd, since the app is shutting down...I
don't care if they've changed at that point). The event handlers run, but
when they get to the combobox objects, they are "empty" and I get the 424
exception.

Am I supposed to be checking some property that says the app is shutting
down or something?



Tom Ogilvy

Run-time error '424' in VBA event handler on XL shutdown
 
Unlink the comboboxes from your worksheet cells and handle this with code in
the change event.

--
Regards,
Tom Ogilvy


"Mike Jones" wrote in message
...
This is getting aggravating! I have several combobox change event

handlers.
They work fine most of the time. But at shutdown, for some reason these
event handlers are firing (which is odd, since the app is shutting

down...I
don't care if they've changed at that point). The event handlers run, but
when they get to the combobox objects, they are "empty" and I get the 424
exception.

Am I supposed to be checking some property that says the app is shutting
down or something?





Mike Jones

Run-time error '424' in VBA event handler on XL shutdown
 
Sorry, I'm unsure what unlinking it from the worksheet cells means. I've
gone into "Format Control" and selected "Don't move or size with cells",
which lowered the number of problems, but I'm still having issues. I am not
using "Linked Cell".



"Tom Ogilvy" wrote in message
...
Unlink the comboboxes from your worksheet cells and handle this with code
in
the change event.

--
Regards,
Tom Ogilvy


"Mike Jones" wrote in message
...
This is getting aggravating! I have several combobox change event

handlers.
They work fine most of the time. But at shutdown, for some reason these
event handlers are firing (which is odd, since the app is shutting

down...I
don't care if they've changed at that point). The event handlers run,
but
when they get to the combobox objects, they are "empty" and I get the 424
exception.

Am I supposed to be checking some property that says the app is shutting
down or something?







Tom Ogilvy

Run-time error '424' in VBA event handler on XL shutdown
 
Never had a problem with this if the comboboxes aren't linked to cells.
Can't imagine what would cause your comboboxes to change and fire your
change event macros.

--
Regards,
Tom Ogilvy

"Mike Jones" wrote in message
...
Sorry, I'm unsure what unlinking it from the worksheet cells means. I've
gone into "Format Control" and selected "Don't move or size with cells",
which lowered the number of problems, but I'm still having issues. I am

not
using "Linked Cell".



"Tom Ogilvy" wrote in message
...
Unlink the comboboxes from your worksheet cells and handle this with

code
in
the change event.

--
Regards,
Tom Ogilvy


"Mike Jones" wrote in message
...
This is getting aggravating! I have several combobox change event

handlers.
They work fine most of the time. But at shutdown, for some reason

these
event handlers are firing (which is odd, since the app is shutting

down...I
don't care if they've changed at that point). The event handlers run,
but
when they get to the combobox objects, they are "empty" and I get the

424
exception.

Am I supposed to be checking some property that says the app is

shutting
down or something?










All times are GMT +1. The time now is 02:30 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com