Component arrays is important in language programming. Similarly in Delphi. Therefore, knowledge of the array must be deep. Below is a discussion about the array of programing delphi.
Below is an example of ARRAY in DELPHI programming :
var
Form1: TForm1;
global
arr: Array[1..10] of TCheckBox;
procedure TForm1.FormCreate(Sender: TObject);
var
i,a,CtlTop : integer;
begin
CtlTop:=8;
for i:=1 to 10 do
begin
arr[i]:=TCheckBox.Create(Self);
arr[i].parent:=Self;

CtlTop:=CtlTop+24;
arr[i].Top:=CtlTop;

arr[i].Caption :='Checkbox' + IntToStr(i);
end;
end;

Categories: