Subject | [IBO] TIB_SessionProps - Capture Error |
---|---|
Author | Vincenzo Scarpellino |
Post date | 2004-10-04T09:13:41Z |
Hi,
I am trying TIB_SessionProps to capture error message (I am using TIBOQuery, TIB_Connection ), but I don't known what is wrong because it doesn't work. I put it on my MainForm where there is TIB_Connection and
set its Session Property to TIB_Connection Session Property (MyIBSessionProps.IB_Session:= MyIBConnect.IB_Session;) and OnError Event I have following code. It does't fire OnError Event. What is wrong ?
How can I capture it ?
Thank You
Best Regards
procedure TMdiForm.IBAziendaSessionPropsError(Sender: TObject;
const ERRCODE: Integer; ErrorMessage, ErrorCodes: TStringList;
const SQLCODE: Integer; SQLMessage, SQL: TStringList;
var RaiseException: Boolean);
begin
case ERRCODE of
isc_no_dup:
begin
SysUtils.Beep;
ShowMessage('Record Duplicato')
Abort;
end;
isc_unique_key_violation:
begin
SysUtils.Beep;
ShowMessage('Record Esistente');
Abort;
end;
end;
end;
--
Email.it, the professional e-mail, gratis per te: http://www.email.it/f
Sponsor:
Scopri il benessere che solo lÂ’aloe vera regala al tuo corpo: cura la tua pelle
* Con la vasta gamma di prodotti che ti offre Erboristeria.com
Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid#80&d=4-10
[Non-text portions of this message have been removed]
I am trying TIB_SessionProps to capture error message (I am using TIBOQuery, TIB_Connection ), but I don't known what is wrong because it doesn't work. I put it on my MainForm where there is TIB_Connection and
set its Session Property to TIB_Connection Session Property (MyIBSessionProps.IB_Session:= MyIBConnect.IB_Session;) and OnError Event I have following code. It does't fire OnError Event. What is wrong ?
How can I capture it ?
Thank You
Best Regards
procedure TMdiForm.IBAziendaSessionPropsError(Sender: TObject;
const ERRCODE: Integer; ErrorMessage, ErrorCodes: TStringList;
const SQLCODE: Integer; SQLMessage, SQL: TStringList;
var RaiseException: Boolean);
begin
case ERRCODE of
isc_no_dup:
begin
SysUtils.Beep;
ShowMessage('Record Duplicato')
Abort;
end;
isc_unique_key_violation:
begin
SysUtils.Beep;
ShowMessage('Record Esistente');
Abort;
end;
end;
end;
--
Email.it, the professional e-mail, gratis per te: http://www.email.it/f
Sponsor:
Scopri il benessere che solo lÂ’aloe vera regala al tuo corpo: cura la tua pelle
* Con la vasta gamma di prodotti che ti offre Erboristeria.com
Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid#80&d=4-10
[Non-text portions of this message have been removed]