ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   What events can be captured in a Class Module? (https://www.excelbanter.com/excel-programming/276319-re-what-events-can-captured-class-module.html)

Tom Ogilvy

What events can be captured in a Class Module?
 
If you are talking about using With Events, you can use the events native to
the MSForms control (Listbox, combobox, textbox, etc). However, events like
Enter, Exit, AfterUpdate and BeforeUpdate belong to the container (the
control object) and aren't available using With Events. Likewise for
GotFocus and LostFocus which belong to the container (oleObject) on the
worksheet.

--
Regards,
Tom Ogilvy


Julian Milano wrote in message
...
Like the subject says.......

Is there a list of which events for which type of controls are available

to
a Classs Module? I'm looking at textboxes at the moment....

--


Julian Milano





Julian Milano

What events can be captured in a Class Module?
 
Thanks Tom,

So is there *anyway* to capture all the AfterUpdate and BeforeUpdate events
of many textboxes or do we have to write a routine for each?

--


Julian Milano

"Tom Ogilvy" wrote in message
...
If you are talking about using With Events, you can use the events native

to
the MSForms control (Listbox, combobox, textbox, etc). However, events

like
Enter, Exit, AfterUpdate and BeforeUpdate belong to the container (the
control object) and aren't available using With Events. Likewise for
GotFocus and LostFocus which belong to the container (oleObject) on the
worksheet.

--
Regards,
Tom Ogilvy


Julian Milano wrote in message
...
Like the subject says.......

Is there a list of which events for which type of controls are available

to
a Classs Module? I'm looking at textboxes at the moment....

--


Julian Milano







Myrna Larson[_2_]

What events can be captured in a Class Module?
 
In the routine for each control, instead of doing the "real work", you can call another sub that
does that.


On Mon, 8 Sep 2003 12:46:58 +1000, "Julian Milano" wrote:

Thanks Tom,

So is there *anyway* to capture all the AfterUpdate and BeforeUpdate events
of many textboxes or do we have to write a routine for each?



Tom Ogilvy

What events can be captured in a Class Module?
 
Not that I am aware of. Someone else may have a different opinion, but I
have never seen a method posted here.

--
Regards,
Tom Ogilvy

Julian Milano wrote in message
...
Thanks Tom,

So is there *anyway* to capture all the AfterUpdate and BeforeUpdate

events
of many textboxes or do we have to write a routine for each?

--


Julian Milano

"Tom Ogilvy" wrote in message
...
If you are talking about using With Events, you can use the events

native
to
the MSForms control (Listbox, combobox, textbox, etc). However, events

like
Enter, Exit, AfterUpdate and BeforeUpdate belong to the container (the
control object) and aren't available using With Events. Likewise for
GotFocus and LostFocus which belong to the container (oleObject) on the
worksheet.

--
Regards,
Tom Ogilvy


Julian Milano wrote in message
...
Like the subject says.......

Is there a list of which events for which type of controls are

available
to
a Classs Module? I'm looking at textboxes at the moment....

--


Julian Milano









Julian Milano

What events can be captured in a Class Module?
 
Thanks Tom & Myrna,

I think Myrna's idea will have to be the best bet for now.

--


Julian Milano

"Myrna Larson" wrote in message
...
In the routine for each control, instead of doing the "real work", you can

call another sub that
does that.


On Mon, 8 Sep 2003 12:46:58 +1000, "Julian Milano"

wrote:

Thanks Tom,

So is there *anyway* to capture all the AfterUpdate and BeforeUpdate

events
of many textboxes or do we have to write a routine for each?






All times are GMT +1. The time now is 07:50 AM.

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