function BeginTrans: Integer;
begin
if DM_Frm.AdoConn.InTransaction then
DM_Frm.AdoConn.RollbackTrans;
Result := DM_Frm.AdoConn.BeginTrans;
end;
procedure CommitTrans;
begin
DM_Frm.AdoConn.CommitTrans;
end;
procedure RollbackTrans;
begin
DM_Frm.AdoConn.RollbackTrans;
end;