Adding click event to generic control?

  • Thread starter Thread starter Stephen Lambie
  • Start date Start date
S

Stephen Lambie

Hi,

I want to develop a custom checkbox. I want to use the existing checkbox
in a custom control where I use the disabled state as a third state. I
need to be able to detect mouse or click events in the disabled checkbox
or the parent custom control.

Is this possible? How does a control like a button control implement
event trapping like a click event?

Thanks for your time.
 
You need to include some client side scripting to handle the the disabled
state.
For example, add an attribute ( eg state ) to your custom control.
Check the attribute on each click. If disabled return false.

A
 
How do I detect a click if the custom control does not have a click
event? A disabled checkbox does not fire any events if disabled. This is
why I need to detect clicks in the parent class/control.
 
Back
Top