I'll second the suggestion to not use generic RELEASE statements and add that if you do or may in the future use more than one data account to add a path variable to your common and check if the current path is different than the common path.
hth Colin Alfke Calgary Canada -----Original Message----- From: Stevenson, Charles Responding to this part only: > Yes the file is being opened withing the subroutine and no, is not > easy to change it to open the file higher in the food chain. SUBROUTINE XYZ( ... ) COMMON /XYZ.ONLY/ XYZ.COMMON.INIT, FVAR IF NOT( XYZ.COMMON.INIT ) THEN OPEN 'whatever-file' TO FVAR ELSE ... Abort ? ... XYZ.COMMON.INIT = @TRUE END READU rec FROM FVAR, 'some-id' ELSE ... RETURN ;* readu lock ON whatever-file some-id is retained ;* and file remains open in /XYZ.ONLY/ common. END The calling program can later release that lock via: OPEN 'whatever-file' TO LOCAL.FVAR ... RELEASE LOCAL.FVAR, 'some-id' BUT !!!NOT!!! By this: OPEN 'whatever-file' TO LOCAL.FVAR ... RELEASE LOCAL.FVAR Yet these 2, within the calling program, WILL cause the record lock on 'some-id' to be released: RELEASE Or: STOP I'm just describing what IS (10.0.16), not whether good or bad. cds ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/