Howdy, Stranger!

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

In this Discussion

Adjust all document TLMDDockPanels with code

is it possible to change all documentpanels (also all floating) as tabbed panels to center of site with code?

I mean when i drop all panels with mouse into the center but whithout mouse, by code?



  • 4 Comments sorted by Votes Date Added
  • You can use the following code (this will include all floating panels, because the we iterate form's Components collection, and because the Owner of components (which is a form) never changes):

    procedure TForm3.Button1Click(Sender: TObject);
      i:   Integer;
      pnl: TLMDDockPanel;
      for i := 0 to ComponentCount - 1 do
        if Components[i] is TLMDDockPanel then
          pnl := TLMDDockPanel(Components[i]);
          if pnl.ClientKind = dkDocument then
            LMDDockSite1.DockControl(pnl, LMDDockSite1.SpaceZone, alClient);
  • Thank you,

    i tested your code, it makes all document dockpanels (also floating) to tabbed documents in the Site.

    I want all documents to be horizontally next to each other with the same width

  • I've answered in another topic.
  • I've answered in that topic, there is a problem
Sign In or Register to comment.