procedure TForm1.Button1Click(Sender: TObject);
begin
with dxDBGrid1.CreateColumn(TdxDBGridButtonColumn) as TdxDBGridButtonColumn do
//谁能解释一下这一句是怎么回事?我是菜鸟,超级菜!
begin
FieldName := 'State';
Index := 2;
OnEditButtonClick := ColEditButtonClick;//这一句在d5里面编译通不过,不知道原因
end;
end;