Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

TLMDDockPanel: easier way to get ActiveControl?

When I undock my TLMDDockPanel, and I need to access the currently active control in the floating form,
is there an easier way than this?

TLMDFloatingForm(Panel1.Parent.Parent).ActiveControl

I appreciate any help,
Cheers,
Alex

Comments

  • 3 Comments sorted by Votes Date Added
  • May be Panel.Site.FloatingForm.ActiveControl...
  • Well, actually, if you compare both methods looking at the CPU window, you will notice that using
    Panel.Site.FloatingForm.ActiveControl will actually generate one extra operation comparing to using
    TLMDFloatingForm(Panel1.Parent.Parent).ActiveControl, so although your suggestion might be a bit more elegant, I'll stick with my first option.
    Thanks anyway
Sign In or Register to comment.