[SOLVED - Pleas ignore]How to use ApplyUpdates in IBX lazarus / 16-Databases ---------------------------------------------------------------------- incendio · 2021-11-24 03:35 Hi guys, Newbie here, I tried to use IBX for my database application. I have codes declaration like these 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   TForm1 = class(TForm)    btnUndo: TButton;    btnSave: TButton;    DataSource1: TDataSource;    Dba: TIBDatabase;    DBEdit1: TDBEdit;    DBText1: TDBText;    Dt: TIBDataSet;    DtCD: TIBStringField;    DtGRP: TIBStringField;    DtID: TIBIntegerField;    Trs: TIBTransaction;    procedure btnSaveClick(Sender: TObject);    procedure btnUndoClick(Sender: TObject);    procedure FormCreate(Sender: TObject);  private   public   end;  Stuck in this codes 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 procedure TForm1.btnSaveClick(Sender: TObject);const  Tbl : array[1..1] of TIBDataSet = (Dt); begin  Dba.ApplyUpdates(Tbl);end;  got an error Error: typed constants of classes or interfaces are not allowed EDIT Change the code to this, seem fix the problem 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 procedure TForm1.btnSaveClick(Sender: TObject);var  Tbl : array [1..1] of TDataSet; begin  Tbl[1] := Dt;  Dba.ApplyUpdates( Tbl);end; ---------------------------------------------------------------------- korba812 · 2021-11-24 10:48 You can also do it like 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 procedure TForm1.btnSaveClick(Sender: TObject);begin  Dba.ApplyUpdates([Dt]);end; ---------------------------------------------------------------------- incendio · 2021-11-24 11:12 Quote from: korba812 on November 24, 2021, 11:48:42 amYou can also do it like 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 procedure TForm1.btnSaveClick(Sender: TObject);begin  Dba.ApplyUpdates([Dt]);end; Nice, thanks for the info.