Q:  How do I move columns with code?

A:  Cheesy hack alert!

  hack = class(TDBGrid);

procedure TForm1.Button1Click(Sender: TObject);
begin
  hack(dbGrid1).ColumnMoved(FromVar, ToVar); // "FromVar" and "ToVar" are integer variables.
end;

Note:  The column locations are a "1" based list (not zero based).  (The column that is the left-most is number 1.)