Procedure fails if field name not in current window

This didn’t matter in Pan 6…in Pan X, the procedure fails when trying to autofill a field which is not visible in the datasheet, but works only if the field in question is visible when the procedure is called.
image

It isn’t shown in your screen shot, but I assume that the code contains this line:

field ReceiptDue

This code will not run if the field is not visible. You cannot switch to a field that is hidden. If Panorama 6 allowed that, it was a bug.