procedure TForm1.Button1Click(Sender: TObject); begin Form1.Height := Form1.Height + x; end;
var ouvert : Boolean; procedure TForm1.FormCreate(Sender: TObject); begin Button1.Caption := 'Ouvrir>>>'; ouvert := False; end; procedure TForm1.Button1Click(Sender: TObject); begin if ouvert then begin Form1.Height := Form1.Height - x; Button1.Caption := 'Ouvrir >>>'; end else begin Form1.Height := Form1.Height + x; Button1.Caption := '<<< Fermer'; end; ouvert := not ouvert; end;