Hi Bruno,
I hope this message finds you well. I'm currently facing an issue related to a form within a TWebScrollbox. My initial goal was to dynamically adjust the form's height within the scrollbox during runtime. This functionality was working perfectly three months ago. However, we have recently upgraded several versions of TMS Web Core, and I've encountered an issue where it no longer functions as expected.
To illustrate this problem, I've attached a sample project here:
27. form height.zip (1.7 MB)
I created a form within a WebScrollbox by clicking the "Create New Form" button and set the form's height to 1000 using the following code:
procedure TForm2.WebButton1Click(Sender: TObject);
procedure AfterCreateDlg(AForm: TObject);
begin
Form1.height := 1000;
end;
beginForm1 := TForm1.CreateNew(WebScrollBox1.ElementID,@AfterCreateDlg);
end;
It seems that the form's height is not being set correctly to 1000. Instead, it consistently appears slightly taller than the scrollbox, regardless of how I resize the window. Please refer to the screenshot below:
I also attempted to change the form's height by clicking another button using the following code:
Form1.height := 500;
However, in this case, the scrollbox's height was modified to 500, rather than the form's height, even though the scrollbox's align property is set to alClient. Please see the screenshot below for reference:
I would greatly appreciate your assistance in resolving this issue. Thank you in advance for your help.