Lock DBGRid column width lazarus / 31-LCL ---------------------------------------------------------------------- Mando · 2016-01-13 10:15 Hi all: How can lock the width of a DBGrid column? I want to allow user resize all columns of my dbGrid except one. (the last) I tried to set maxwidth and minwidth but it doesn't work. Can anybody help me with this?? Thanks. ---------------------------------------------------------------------- balazsszekely · 2016-01-13 11:08 Hi Mando, Try this: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i var  MDown: Boolean; procedure TForm1.DBGrid1MouseDown(Sender: TObject; Button: TMouseButton;  Shift: TShiftState; X, Y: Integer);begin  MDown := True;end; procedure TForm1.DBGrid1MouseMove(Sender: TObject; Shift: TShiftState; X,  Y: Integer);var  ACol, ARow: Integer;begin  if MDown then    Exit;  DBGrid1.MouseToCell(X, Y, ACol, ARow);  if (ARow = 0) and  (ACol = 6) then    DBGrid1.Options := DBGrid1.Options - [dgColumnResize]  else    DBGrid1.Options := DBGrid1.Options + [dgColumnResize];end; procedure TForm1.DBGrid1MouseUp(Sender: TObject; Button: TMouseButton;  Shift: TShiftState; X, Y: Integer);begin  MDown := False;  DBGrid1.Options := DBGrid1.Options + [dgColumnResize];end; ---------------------------------------------------------------------- Mando · 2016-01-13 11:59 Hi, Getmem!! Thanks a lot, It works!!. But I search a way to do it without code, using some control property. Why maxwidth/minwidth don't work??? thanks. ---------------------------------------------------------------------- balazsszekely · 2016-01-13 12:31 QuoteThanks a lot, It works!!. You're welcome! I'm glad it's working! QuoteBut I search a way to do it without code, using some control property. Why maxwidth/minwidth don't work??? Probably it's a bug.