Hi Demetrios,
If you get Error 1539, then use
AERROR(laError),
and you'll get:
laError[1]: 1539
laError[4]: Workaerea of the table for which the trigger failed, so Alias(laError[4]) gives the Alias.
laError[5]: 1 - Insert Trigger failed, 2 - Update Trigger failed, 3- Delete Trigger failed
But that is it. You won't know which reference or foreign
key to which second table is the reason for the error.
In a 3rd-Party Referential Integrity Code (ri-code)
builder called AMRI they added code into the trig-
gers, that generates a global variable with the exact
reason of the trigger failure, so you could then
use that. The foxpro ri-code is not very readable,
so it's a bit hard to extend that code and you
risk loosing the code the next time you rebuild
the ri-code...
AMRI has a german GUI and I don't know if there
is an english version planned.
If you don't mind that you could get it here:
ftp://ftp.prolib.de/public/VFP/AMRI320.zip
Bye, Olaf.