LISTLOCK-NEXT
The LISTLOCK-NEXT function retrieves the next item in the list.
Syntax:
 CALL "A$LIST_LOCKS" USING LISTLOCK-NEXT 
                           listHandle
                           fileName 
                           threadID
                           openMode
                           lockMode 
                           keyVal
                           keyLen 
Parameters:
LISTLOCK-NEXT
Constant
 
listHandle
USAGE HANDLE
Specifies the handle of a list, returned by the LISTLOCK-OPEN function
fileName
PIC X(n)
Receives the name of the file where the lock is.
threadID
PIC 9(n)
Receives the thread ID of the Client that is locking the record. To have additional information you can call the A$GET_USER routine passing this ID to it
openMode
PIC 9
Receives the way by which the file was open. Possible values are:
1... Input
2... Output
3... I-O
6... Extend
8... Transaction
lockMode
PIC 9(4)
Receives the lock mode applied to the file. The value is the sum between one or more of the following values:
0... None
1... Exclusive
2... Allowing No Others
3... Allowing Readers
4... Allowing Writers
5... Allowing Updaters
6... Allowing All
 
128... Automatic
256... Multiple Records
512... Mass Update
1024... Bulk Addition
2048... Transaction
 
keyVal
PIC X(n)
Receives the value of the primary key of the locked record. This field is intialized to "" when the lock is on the whole file.
keyLen
PIC 9(n)
Receives the length in bytes of the primary key of the locked record. A length of zero means that the lock is on the whole file.
Return code:
returnCode can be any numeric data item and provides additional information:
0
No more items available.
>0
Information returned correctly.