>I would like to use rlock to determine if a record is locked. I have two instances of VFP (SP3) running. In the first instance I open a table, shared, with no buffering and set reprocess to 0. Then I issue rlock() on a specific record. Then in the second instance of VFP, I do all the same setup. When I issue rlock() on that same record I expect it to return false. Instead it hangs.
>
>Can anyone tell me why this is happening?
>
>Thanks much in advance for any assistance you might offer.
>
>BTW, isrlocked() works fine in the original instance, but does not yield correct results in the second session.
With reprocess set to 0, the 2nd copy will try forvever to get a lock and can't, at least not until the 1st copy releases the lock (UNLOCK). You should be seeing a message at the bottom, at least you will if your status bar is on, and SET NOTIFY is on.
If what you want to do is try for some specified amount of times or retries, SET REPROCESS TO x for a number of tries or SET REPROCESS TO x SECONDS to retry for a # of seconds.