Roelaux,
Besides the extra code on the scan line (NOT EOF()) which is not necessary. The problem is the WHILE clause on the REPLACE command. The default scope for REPLACE is the current record, when you add a WHILE clause you cause REPLACE to move the record pointer forward. Dump the WHILE clause and your loop shouild work fine.