SET MULTILOCKS ON && Required for row or table buffering and allows multiple records to be locked using LOCK( ) or RLOCK( )
SET REFRESH TO 5,3
SET REPROCESS TO 5 SECONDS
Above are the setting for locking table BUT want to stop until or unless counter table Locked
For Locking using the following code
LOCAL isLocked , nKey
SELECT Counter
WAIT WINDOW 'Trying to Lock [ Computer No ] Table .... ' NOWAIT
do while ! m.isLocked
m.isLocked = flock('Counter')
enddo
RETURN m.isLocked
But not pausing the process until or unless file locked
SET REFRESH TO 5,3
SET REPROCESS TO 5 SECONDS
Above are the setting for locking table BUT want to stop until or unless counter table Locked
For Locking using the following code
LOCAL isLocked , nKey
SELECT Counter
WAIT WINDOW 'Trying to Lock [ Computer No ] Table .... ' NOWAIT
do while ! m.isLocked
m.isLocked = flock('Counter')
enddo
RETURN m.isLocked
But not pausing the process until or unless file locked