There is no exception raised. As it turnes out I have found the reason the
locate method failed - it was because the text I was searching for was misspelt
in the database (somehow I missed the spelling error the first 20 times I
checked for it :-). However, it's still an interesting question because if you
follow the vcl source code to the point where it makes the call to the bde, an
error code *is* returned and checked against the constant DBI_NOERROR (or
something similar - I can't check it at the moment). So apparently even thought
the locate function does not raise an exception if it fails, it does receive an
error code back from it's call to the BDE, and it then returns false from the
locate function. Stepping through that code I think the error code returned was
something like 8172 so I was wondering (even though it's irrelevant now) if
there was a call to obtain that error code - effectively the last error
encountered by the BDE.


Phil.




"Patrick Dunford" <[EMAIL PROTECTED]> on 11/10/99 14:39:32

Please respond to [EMAIL PROTECTED]

To:   Multiple recipients of list delphi <[EMAIL PROTECTED]>
cc:    (bcc: Phillip Middlemiss/NZ Forest Research Institute/NZ)

Subject:  RE: [DUG]:  BDE Error



> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
> Behalf Of [EMAIL PROTECTED]
> Sent: Tuesday, 12 October 1999 10:27
> To: Multiple recipients of list delphi
> Subject: [DUG]: BDE Error
>
>
> Hi,
>
> A call that I am making to the locate method is failing and I
> want to get the
> error code back so I can call DBIError with it. Is there a
> routine that will
> return the last error code from the bde?

If you're getting an EDBEngineError exception then there's an error code
attached to each error. (TDBError)

This is the BDE error result.

Most calls to the BDE use Check procedure passing the DBI method name and
parameters, check will raise the exception if an error result is returned
IIRC.

============================================
Patrick Dunford, Christchurch, NZ
http://patrick.dunford.com/

---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz






---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz

Reply via email to