*-- Lock file nHandle = fopen( 'MyFile', 0 ) if nHandle < -1 *-- File not locked endif *-- The code "nHandle = fopen( 'MyFile', 0 )" will return -1 for *-- any other user on another PC. Correct? *-- Unlock file if nHandle > 0 fclose( nHandle ) endifI want also to be sure that if the user shuts down his/her computer, the lock on the file 'MyFile' is released.