Error: WinControl.WMSize loop detected, lazarus / 31-LCL ---------------------------------------------------------------------- BlueIcaro · 2014-03-08 00:18 Hi, trying to put a form into a panel, I got this exception: QuoteWinControl.WMSize loop detected, the widgetset does not like the LCL bounds or sends unneeded wmsize messages:My code is Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i procedure TForm1.Button1Click(Sender: TObject);Var     f: TForm2;begin  f := TForm2.Create(Panel1);  F.Parent := Panel1;  F.Show;  F.Align:=alClient;  F.Visible:=True;end;  Any idea? I using Lazarus 1.12 release in W7/64 Thanks /BlueIcaro ---------------------------------------------------------------------- irfanbagus · 2014-03-08 03:03 try to add Code: [Select]F.BorderStyle:= bsNone; before show form ---------------------------------------------------------------------- howardpc · 2014-03-08 10:38 Parenting a form from a TWinControl is not good design, and probably will rely on hacks to make it workable. Better to use a TFrame descendant for whatever you want to do in your panel. Indeed, a TFrame descendant should obviate the need for a panel altogether, and can be parented by the panel's form. What does the panel add that makes it essential? ---------------------------------------------------------------------- BlueIcaro · 2014-03-08 14:04 Thanks for the answers. I'll take a look frame as say  howardpc But Frames are full developed in Lazarus 1.2? /BlueIcaro ---------------------------------------------------------------------- kpeters58 · 2014-03-08 21:27 I show forms on panels/scrollboxes all the time (and have done so in commercial apps for years without any ill effects). I only saw the error you describe when the form in question had a window state of wsMaximized - I set it to wsNormal and all was well. This refers only to Lazarus - on Delphi this particular issues does not exist.