Hola Rofocale.
Yo uso Delphi 7 y por supuesto no me dá ese error. No sé que pueda estar pasando, no creo que Delphi 2010 haya
cambiado tanto como para no aceptar un código tán simple. Supongo que las propiedades
TForm.ComponentCount y
TForm.Components debe soportarlas.
Fijate así, sólo para probar, por que sinceramente no tengo idea de Delphi 2010.
Código Delphi
[-]
procedure TForm1.FormCanResize(Sender: TObject; var NewWidth,
NewHeight: Integer; var Resize: Boolean);
var
i:Integer;
begin
for i:= 0 to Self.ComponentCount - 1 do
begin
TControl(Self.Components[i]).Left:=
Round(NewWidth * TControl(Self.Components[i]).Left / Self.Width);
TControl(Self.Components[i]).Top:=
Round(NewHeight * TControl(Self.Components[i]).Top / Self.Height);
end;
end;
De todos modos este código ajusta las posiciones de los componentes, no el tamaño.
Saludos.