• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1010
  • Last Modified:

OnExit & OnEnter handling with Components

I am not very experienced with component writing, and all I want to do is handle the OnEnter and OnExit events on a Tedit-derived component.
1 Solution
And what?

Do you want to handle these events internally in the derived class? Do you want to avoid to assign event handlers to OnEnter/OnExit to leave them for the user?

If all applies then override:

    procedure DoEnter; override;
    procedure DoExit; override;

so your new control can act on these events. Don't forget to call the inherited method or the OnEnter/OnExit event will never be called.

Ciao, Mike
bogieman_Author Commented:
Thanks - I already figured it out though so it was a bit of a waste!

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

Tackle projects and never again get stuck behind a technical roadblock.
Join Now