[Gambas-user] Re; Error handling

Benoit Minisini gambas at ...1...
Sun Jul 22 14:16:58 CEST 2007


On jeudi 19 juillet 2007, Gareth Bult wrote:
> Ok,
>
> So ... I need to distinguish between program errors (in which case I
> display an error message) and database disconnections (im which case I
> auto-reconnect) .. reading the text of the error message is such a bad
> solution on sooooo many levels ...
>
> Is there an alternative ?
>
> Gareth.
>

I added a new Connection.Error integer property in the last revision.

It returns the error code of the last error raised by the underlying database 
driver. This error code may not be accurate in all database drivers. But I 
think it is for the mysql driver.

Regards,

-- 
Benoit Minisini




More information about the User mailing list