Best way to make LABEL's clickable in CF 1.0?
Hi,
There's no working Label.Click() event in CF 1.0 at this time. I can't use read-only textbox in this situation, because I need to use a label appearance rather than a textbox appearance.
What is the best workaround to make a label clickable in CF 1.0? I have multiple Label's inside a Panel control, each of which requires a separate click event.
Would it be even easier to essentially inherit the Label control somehow, and add click functionality? Or will I have to write the whole control itself?
I'm deciding on which route is easiest. I just need something identical to Label, except with a click event, that can be easily be used as a drop-in replacement for Label.
Sorry no.
How would you offer the Click event in your new control? Either you have to expose the existing Click event (which we established isn't supported) or handle MouseDown/Up and create your own Click event, but they are not supported either; so you have to roll your own control if you really need this functionality. Check out the article I linked, it actually isn't that much work.
Cheers
Daniel
I did. I'll take a serious look at it.
The reason I am doing this is that checkboxes do not support wordwrapped text, so I am using a Label next to a CheckBox, but I lose the functionality of being able to click on the text to toggle the checkbox on and off.