ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/public/ibx/branches/journaling/examples/employee/unit1.pas
(Generate patch)

Comparing ibx/branches/journaling/examples/employee/unit1.pas (file contents):
Revision 362 by tony, Tue Dec 7 13:27:39 2021 UTC vs.
Revision 363 by tony, Tue Dec 7 13:30:05 2021 UTC

# Line 373 | Line 373 | end;
373   procedure TForm1.FormClose(Sender: TObject; var CloseAction: TCloseAction);
374   begin
375    FClosing := true;
376 <  if IBTransaction1.InTransaction then
377 <    IBTransaction1.Commit;
376 >  try
377 >    if IBTransaction1.InTransaction then
378 >      IBTransaction1.Commit;
379 >
380 >  except on E: Exception do
381 >    begin
382 >      MessageDlg(E.Message,mtError,[mbOK],0);
383 >      IBDatabase1.ForceClose;
384 >    end;
385 >  end;
386   end;
387  
388   procedure TForm1.FormShow(Sender: TObject);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines