Smiffy
26th February 2002, 13:38
Is there an easy way to do this ? I have seen the baan help on on.old.occ etc.

I simply wish to check if a field value has changed since it was last read, (when saving the record). I then wish to do some extra processing if this is the case (& if the new value is a required value).

Is there a function to do this, rather than storing the field value after read and checking it before write/rewrite ?

evesely
26th February 2002, 16:13
In the before.rewrite, you could use on.old.occ. If you only had a small number of fields you wanted to check, this could be done by saving the current values in global variables and then doing a comparison in an on.old.occ call. If you had a lot of fields to check, I suppose you could do something slick using a table record (e.g., rcd.ttdsls040 and a based variable with alloc.mem) and an on.old.occ call.