problem with GridMouseUp lazarus / 9-Editor ---------------------------------------------------------------------- r000 · 2006-12-07 00:43 Hi! In delphi I can use the following code any errors: procedure TForm1.GridMouseUp(Sender: TOBject; Button: TMouseButton;   Shift: TShiftState; X, Y: Integer); var   c:integer; begin   with grid do   if y<=rowheights[0] then   begin     c:=x div (defaultcolwidth+gridlinewidth);     if c>fixedcols-1 then sortgrid(grid,c);  end; end; In lazarus I get two hint and the code doesn't work.     sort.pas(17,44) Hint: Parameter "Button" not used sort.pas(18,7) Hint: Parameter "Shift" not used Please, anybody have an idea about the problem? in lazarus GridMouseUp is different? thanks ---------------------------------------------------------------------- Marc · 2006-12-07 10:22 Hints are not errors. It means that the compiler warns/hints more than delphi. ---------------------------------------------------------------------- Danail · 2006-12-07 11:27 It only says that you can use these options, but you don't have to. If the OnMouseUp do not works make sure that you have choosen it in the OnMouseUp event in the ObjectInspector. ---------------------------------------------------------------------- jesusr · 2006-12-09 05:37 Quote from: "r000"Hi! In delphi I can use the following code any errors: procedure TForm1.GridMouseUp(Sender: TOBject; Button: TMouseButton;   Shift: TShiftState; X, Y: Integer); var   c:integer; begin   with grid do   if y<=rowheights[0] then   begin     c:=x div (defaultcolwidth+gridlinewidth);     if c>fixedcols-1 then sortgrid(grid,c);  end; end; In lazarus I get two hint and the code doesn't work.     sort.pas(17,44) Hint: Parameter "Button" not used sort.pas(18,7) Hint: Parameter "Shift" not used Please, anybody have an idea about the problem? in lazarus GridMouseUp is different? thanks The grid MouseUp should work, but the X value may not be what you expect because it assumes that internal implementation is the same as in Delphi and it assumes also that implemetation won't change. Lazarus grid have a specific event when clicking a column header: OnHeaderClick you might what to use that instead.