delphi4arab منتديات دلفي للعرب

نسخة كاملة : كيف تجعل SpeedButton تتراصف على TForm
أنت حالياً تتصفح نسخة خفيفة من المنتدى . مشاهدة نسخة كاملة مع جميع الأشكال الجمالية .
كيف تجعل SpeedButton تتراصف على Tform
;كيف نجعل Top تعمل سطر جديد

إقتباس :for j := 0 to 40 do
begin
inc(count);
SpeedButton := TSpeedButton.create(self);
with SpeedButton do
begin

if count < 5 then
begin
Top:=22;
left := ComponentIndex * 25;
end;

يبدو اني نسيت اشياء كثيرة ههه
الحل
كود :
var i: integer; SpeedButton: TSpeedButton; begin for i := 0 to 89 do begin SpeedButton := TSpeedButton.Create(Self); with SpeedButton do begin Parent := Panel1; Caption := IntToStr(i); Left := ((i) mod 5) * 25 + 2; Top := ((i) div 5) * 25 + 2; Font.Style := [fsBold]; end; end; end;