Microsoft KB Archive/104048
PRB: "Record Not Locked" with BROWSE NOEDIT or NOMODIFY
The information in this article applies to:
Issuing a BROWSE command with the NOEDIT or the NOMODIFY clause with a shared database while you are setting the delete tag of any record except the current record produces the error message "Record not locked."
The record tagged for deletion does not match the current record pointer; as a result, the desired record cannot be locked prior to being flagged for deletion.
To correct the problem, issue an ON ERROR routine to trap the message prior to issuing the USE <database> SHARED and BROWSE commands. This routine will allow the tagged record to be selected even when it is not the current record.
CLEAR ON ERROR DO errhand WITH ERROR( ), MESSAGE( ) *** Errhand *** PROCEDURE errhand PARAMETER errnum,message If Errnum = 130 On Error * Endif RETURN
Steps to Reproduce Problem
1. Issue the following commands:
USE <database> SHARED BROWSE NOEDIT && or BROWSE NOMODIFY
2. Click the delete tag of any record except the current record. The message "Record not locked" appears. When the message is cleared, the record that was unsuccessfully flagged is now the current record and can be deleted.
Additional reference words: FoxDos FoxWin 2.00 2.50 2.50a errmsg err msg 2.50b 2.60 KBCategory: kbprg kberrmsg kbprb KBSubcategory: FxprgBrowse
Last Reviewed: June 27, 1995