Saving previous values of fields

Saving previous values of fields

Post by norma » Fri, 02 Sep 2005 07:32:33

My app needs to compare previous value with current value of every field.
Is there any way to save previous field value (maybe using a ADOQuery property, etc) without creating global variables?
With many fields (this is my case) the things become very complex and I want to avoid that.


Saving previous values of fields

Post by Del » Fri, 02 Sep 2005 11:44:28

fieldbyname('myfield').asstring = 'xxxx';
fieldbyname('myfield').oldvalue = what was there before xxxx was put
fieldbyname('myfield').currentvalue = what is actually on the disk ( may
have been modified by another user.)

This is true for sql server and access ... dont know for sure about other

ps ... it might be fieldbyname('myfield').currvalue ..... havent coded it
for a while ... look up in help file