begin
with Table1 do
begin
Active := False; { The Table component must not be active }
{ First, describe the type of table and give it a name }
DatabaseName := 'DBDEMOS';
TableType := ttParadox;
TableName := 'CustInfo';
{ Next, describe the fields in the table }
with FieldDefs do
begin
Clear;
Add('Field1', ftInteger, 0, True);
Add('Field2', ftString, 30, False);
end;
{ Next, describe any indexes }
with IndexDefs do
begin
Clear;
{ The first index has no name because it is a Paradox primary key }
Add('', 'Field1', [ixPrimary, ixUnique]);
Add('Fld2Indx', 'Field2', [ixCaseInsensitive]);
end;
{ Now that we have specified what we want, create the table }
CreateTable;
end;
end;
2:
table1.first;
for i:=0 to table1.fields.count-2;
begin
dbgrid1.columns.title.caption:=table1.feildbyname('EnglishFieldNmae').asstring;
table1.next;
end;
table1.first;