The %write() function writes the number of bytes designated by size from var to the file specified by file.descriptor returned by a previous call to %open(), %creat(), or %dup().
Syntax
n = %write(file.descriptor, var, size) |
Description
This function returns the number of bytes actually written. If the length of var is less than size, the content of the string written is undefined, as is usual in C. No data translation occurs.
Example(s)
n=len(item) if %write(fd,item,n)<n then crt "write error" |