TdxDBGridController how to for dummies? lazarus / 21-General ---------------------------------------------------------------------- Arskin_Fertrubble · 2025-06-26 06:43 I recently started using Lazarus4. However, in my experience the RX components, which I had been using in Laz3,  no longer compile with the IDE.  Looking around for a better DBgrid than the standard offering I noticed TdxDBGridController. The documentation for the component mentions a TdxDBGridController.dbgrid property- I don't see it in the property editor (F11)(?).  I tried assigning dxDBGridController1.dbgrid := mydbgrid; at form create, but it seems to have no effect. Some practical advice how to integrate the component in with a TDBgrid  would be most welcome. Thanks ---------------------------------------------------------------------- jamie · 2025-06-27 00:58 I looked at the source code, its looks suspiciously hacked. I saw something in the code that I won't get into atm. Jamie ---------------------------------------------------------------------- paweld · 2025-06-27 04:33 A sample project is provided with the component, you can download, for example, from here: https://gitlab.com/lazaruscomponent/dbgridcontroll er/-/tree/master/demo?ref_type=heads From the object inspector, you can't assign the DBGrid property because it isn't published, but from the code level you can do it without a problem: https://gitlab.com/lazaruscomponent/dbgridcontrolle r/-/blob/master/demo/mainformdemo.pas?ref_type=heads#L367 ---------------------------------------------------------------------- jamie · 2025-06-27 23:07 After examining the source files, I see where there is a potential problem with the assigned TDBGrid.  The Grid that is getting assigned must also be created in the same unit for it to work because a local subclassing of the TDBGrid has been done to add a message event and field of a TdxDBGridController.  If you assign a TDBGrid that has been created outside this then, these extra fields do not exist however, they do in the local copy definition.   What this means is, Assignment to the internal Fgrid from an external TDBGrid created in another unit isn't going to work very well.  You would also need to perform that subclassing trick in the external unit that created the TDBGrid so that it too has that added field. 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  TDBGrid = Class(DBGrids.TDBGrid)   private      FDBGridController: TdxCustomDBGridController;      Procedure WMHScroll(Var Msg: TWMHScroll); message WM_HSCROLL;   End;  if you see there, you can now understand the problem here. I wanted to add that if you were to place this component's unit at the end of the list of where the TDBgrid is, then when the control gets created, it may see the modified version instead. Jamie