Do not modify record if found with recref.GETRECORD

ajhvdbajhvdb Member Posts: 672
edited 2012-02-22 in NAV Three Tier
Just stumbled onto this post: http://navigateintosuccess.com/blog/bug ... services-2
Excellent blog by the way..

Below code will modify the field but also reset all the non-key fields of the record to their default values.
RecRef := RecID.GETRECORD;
// iFldID is an integer parameter
FldRef := RecRef.FIELD(iFldID);
FldRef.VALIDATE(0D);
RecRef.MODIFY;

I was going to use this kind of code but can't after reading this.. Is there a fast workaround?

Thanks for helping.

Comments

Sign In or Register to comment.