In the previous section dedicated to table triggers, we referred to the fields of the current table by simply naming these fields, such as Starting Date, Ending Date, or Customer Group Code. In fact, these fields belong to a global variable, Rec, that always exists within the context of a table and refers to the table instance itself. References to table fields are implicitly resolved to Rec if the record context is not specified explicitly.
Any data manipulation functions are also applied to the context of the current record instance when called without a variable reference. If, for example, we want to make sure that the user fills the item code in the contract line before specifying the amount, we could do it by calling TESTFIELD on the Item No. in the context of the current record. Here is the code to do the validation in the the OnValidate trigger...