Mega Code Archive

 
Categories / Delphi / ADO Database
 

How to allow column resize in a TDBGrid but prevent move

Title: How to allow column resize in a TDBGrid but prevent move Problem: How to allow column resize in a TDBGrid but prevent move ? Unlike the TStringGrid, the TDBGrid has no goColMoving Property published. So here's a workaround for it: TStringGrid(DBGrid1).Options:= TStringGrid(DBGrid1).Options-[goColMoving]