Events implemented in parent class not available in inheriting class (Xojo)

OK I must be missing something here. I have a control subclassed from DesktopComboBox that implements Opening() and FocustLost(). It is called DesktopComboBoxAutoComplete.

A control of type DesktopComboBoxAutoComplete does not allow me to implement Opening() or FocustLost() in the IDE. So if I want to augment that behavior (call Super.Opening() at some point in the control’s Opening event) there’s no way to do it. It’s like those methods are sealed once implemented.

Is this “by design” or something? Any workaround?

Or must I make a subclass DesktopComboBoxAutoComplete with the required changes before dropping it on the designer?

You have to create new Opening and FocusLost events to mirror the ones you’ve already used. So in the Opening event of DesktopComboBox you’ll raise the Opening event you’ve created. I forget the mechanism but you can right click on the Opening event and there’s a menu option to define a new event using the selected one.

Sorry, haven’t touched Xojo in a few months so the exact commands get a little fuzzy.

Create Event Definition from Event:
image

Thanks, Alberto … So now I would have an Event Definition Opening() as well as an Event Handler Opening() … which I could then raise from the child class, if I’m following that correctly.

Yes - once a control implements the event in order you have to add an event definition and reraise the event to make it so other instances can implement the event