Marking records causes Confirmation to pop up

Hi I am trying to mark records in a Bank Reconciliation screen through code, but each time I get one Cofirmation Screen popping-up asking me if I want to rename the record. It doesn’t matter if I click yes or no because once the confimation box disappears the form shows the marked records correctly. Why does the confirm box pop-up? Below is the code I am using: I have also tried using another record variable and assigning it to the REC instance, but it makes no difference. IF Rec.FIND(’-’) THEN BEGIN REPEAT IF (Rec.“Matching Bank Stmt Entry No.” = 0) THEN Rec.MARK(TRUE); UNTIL Rec.NEXT = 0; Rec.MARKEDONLY(TRUE); END;

Why not just use SETRANGE(“Matching Bank Stmt Entry No.” ,0); This will also filter on records where “Matching Bank Stmt Entry No.” = 0.