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

Comparing ibx/trunk/examples/employee/unit1.pas (file contents):
Revision 401 by tony, Mon Jan 10 10:13:17 2022 UTC vs.
Revision 402 by tony, Mon Aug 1 10:07:24 2022 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