>SET EXCLUSIVE ON >SELE acomp >IF LOCK('acomp') != .T. > loopcount = 0 > DO WHILE LOCK('acomp') = .F. .OR. loopcount = 200 > IF LOCK('acomp') = .T. > EXIT > ENDIF > loopcount = loopcount + 1 > ENDDO >ENDIF >IF LOCK('acomp') != .T. > =MESSAGEBOX('Please try again.',64,'Too much Network Traffic.') > THISFORM.RELEASE >ENDIF >THISFORM.curordnum = acomp.nextfakenum >REPLACE acomp.nextfakenum WITH acomp.nextfakenum + 1 >TABLEUPDATE(2,.T.,'acomp') >UNLOCK IN acomp >SET EXCLUSIVE OFF>Does anyone see where this is going wrong? It works fine 95% of the time. This is a multi-user application, but I think most of the dups are happening from the same session.