I have a form (Fire Monkey) with multiple frames on it.

I have a form (Fire Monkey) with multiple frames on it. I would like to execute some common code (same code for all frames) when the focus enters a frame and exists a frame. Can anyone assist with some example please? I tried setting the OnEnter and OnExit in the Frame definition and also on the Frame instances, but none worked. If I set it on a control on the Frame it works, but I need to know when a frame becomes focused, irrespective of the controls on it.
In short, using this, I want to know where in my form the focus is at any point in time.
I need to load the frames at runtime, so I will need to link the events also at runtime I think.

Comments