05-05-2014, 03:33 PM
بنفس المنطق السابق (مع ان الطريقة ركيكة!)
كود :
procedure TForm1.Button1Click(Sender: TObject);
begin
if color=clRed then color:=clGreen
else if color=clGreen then color:=clBtnFace
else if color=clBtnFace then color:=clred;
if caption='Form1' then caption:='One'
else if Caption='One' then Caption:='Two'
else if Caption='Two' then Caption:='Three'
else Caption:='Form1';
end;
