isCOBOL Evolve : Appendices : Library Routines : R$IO : R-REWRITE-FUNCTION
R-REWRITE-FUNCTION
This function rewrites a record in the relative file. It doesn’t change the file position.
Syntax:
 SET R-REWRITE-FUNCTION TO TRUE
 
 CALL "R$IO" USING RIO-FUNCTION 
                   f
                   recBuffer
                   lenght
                   keyVal 
            GIVING returnCode
Parameters:
f
the file handle returned by R-OPEN-FUNCTION.
recBuffer
an alphanumeric data-item that contains the new record data.
length
number of bytes to write.
keyBal
record number to write
Return code:
returnCode can be any signed numeric data item and provides additional information:
>0
Operation successful.
0
Operation failed.