translation lock message

Discussion of open issues, suggestions and bugs regarding UniDAC (Universal Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
cvitoria
Posts: 3
Joined: Mon 14 Sep 2009 08:54

translation lock message

Post by cvitoria » Tue 15 Sep 2009 09:53

Hi,

How to trap and/or translate the lock message ?

Thanks

Carlos

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Wed 16 Sep 2009 12:37

You can use the OnError event of TUniConnection to process the error.

The error for a locked record may have different error code and text for different DBMS. To know that an exception is a lock error, you need to compare the error code or message of the exception to some values specific for each provider.

Then you can assign another value to the Message property of an exception.

Post Reply