unit Unit2;

interface

uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.StdCtrls;

type
  TForm2 = class(TForm)
    Button1: TButton;
    Button2: TButton;
    ListBox2: TListBox;
    Label1: TLabel;
    Label2: TLabel;
    Label3: TLabel;
    Label4: TLabel;
    Button3: TButton;
    Label5: TLabel;
    procedure Button1Click(Sender: TObject);
    procedure Button2Click(Sender: TObject);
    procedure FormCreate(Sender: TObject);
    procedure Label2Click(Sender: TObject);
    procedure Label3Click(Sender: TObject);
    procedure Label4Click(Sender: TObject);
    procedure Button3Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form2: TForm2;

implementation

{$R *.dfm}
uses unit1;
procedure TForm2.Button1Click(Sender: TObject);
begin
dataRAMallocator;
end;

procedure TForm2.Button2Click(Sender: TObject);
begin
 halt;
end;

procedure TForm2.Button3Click(Sender: TObject);
begin
 form2.ListBox2.Clear;
end;

procedure TForm2.FormCreate(Sender: TObject);
begin
 sliceNbr:=4000000; nc:=128; nbrOfLayers:=10;
 Label1.Caption:='';
 label2.Caption:='UP='+intToStr(sliceNbr)+'; Click';
 label3.Caption:='Vect='+intToStr(nc)+'; Click';
 label4.Caption:='Layers='+intToStr(nbrOfLayers)+'; Click';
 label5.Visible:=false;
end;{FormCreate}

procedure TForm2.Label2Click(Sender: TObject);
begin
 sliceNbr:=strToInt(inputBox('Upper value','UP=',intToStr(sliceNbr)));
 label2.Caption:='UP='+intToStr(sliceNbr)+'; Click';
end;

procedure TForm2.Label3Click(Sender: TObject);
begin
 nc:=strToInt(inputBox('Vector length','Vect=',intToStr(nc)));
 label3.Caption:='Vect='+intToStr(nc)+'; Click';
end;

procedure TForm2.Label4Click(Sender: TObject);
begin
 nbrOfLayers:=strToInt(inputBox('Nbr of layers','Layers=',intToStr(nbrOfLayers)));
 label4.Caption:='Layers='+intToStr(nbrOfLayers)+'; Click';
end;

end.
