ATTACH - open existing file.
(obsolete - Use OPEN) 
Usage:
call attach(lgu,catfil,iprmis,mode,istat,buffer)
Where:
    - lgu 
 
    - is an integer variable or constant and is the usual F77
        unit reference. 
 
    - catfil 
 
    - is a character expression which is the catalog/file
        descriptor containing the catalog/file string and must be
        terminated by a semicolon. Embedded blanks are ignored. 
 
    - iprmis 
 
    - is an integer expression that gives the desired
        permission which is OR'd with any permission in catfil. 
            - 1 
 
            - access for read 
 
            - 2 
 
            - access for write 
 
            - 3 
 
            - access for read and write 
 
        
     
    - mode 
 
    - is an integer expression 
            - 0 
 
            - access file as defined 
 
            - 1 
 
            - access file as random 
 
            - 2 
 
            - open the terminal 
 
        
     
    - istat 
 
    - is an integer variable where there status is returned.
        The status is either the first FMS status word or: 
            - 0 
 
            - success 
 
            - 1 
 
            - "lgu" already open. 
 
            - 2 
 
            - attempt to access terminal in batch 
 
            - 3 
 
            - denied because of insufficient memory 
 
            - 4 
 
            - file name all blanks 
 
        
     
    - buffer 
 
    - is an array of 380 words to be used by FMS. It may be a
        null argument, in which case ATTACH will dynamically
        allocate the space. 
 
Description:
ATTACH opens an existing permfile. This subroutine is obsolete
and can better be done with an OPEN statement within the F77
program.
Copyright © 1996, Thinkage Ltd.