C$DELETE

Deletes a file.

Syntax:

CALL "C$DELETE"
   USING file-name, [file-type,]
   [GIVING status]

Parameters:

file-name
PIC X(n)
file-type
PIC X
status
Any numeric type

On Entry:

file-name
The pathname of the file to be deleted
file-type
The file organization of the filename. It must be one of: S (for sequential), R (for relative) or I (for indexed).

This defaults to S if not specified.

On Exit:

status
Returns zero if the delete is successful, or non-zero if not.

Comments:

To obtain an extended file status code for this operation, define status as comp xx comp-x and follow the example in Extended File Status Codes.