02.07.2013 Views

HP Fortran Programmer's Reference

HP Fortran Programmer's Reference

HP Fortran Programmer's Reference

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

POSITION=character-expression<br />

Table 10-39<br />

<strong>HP</strong> <strong>Fortran</strong> statements<br />

OPEN<br />

specifies the position of an existing file to be opened for sequential access.<br />

character-expression canbeoneofthefollowingarguments:<br />

'ASIS' Leave file position unchanged<br />

(default).<br />

'REWIND' Position the file at its start.<br />

'APPEND' Positionthefilejustbeforethe<br />

end-of-file record.<br />

RECL=integer-expression<br />

STATUS=character-expression<br />

Table 10-40<br />

If the file to be opened does not exist, this specifier is ignored. New files are<br />

always positioned at their start.<br />

specifies the length of each record in a file to be opened for direct access. The<br />

length is measured in characters (bytes). This specifier must be present<br />

when a file is opened for direct access and is ignored if file is opened for<br />

sequential access.<br />

specifies the state of the file when it is opened. character-expression can<br />

be one of the following arguments:<br />

'OLD' Open an existing file. FILE=<br />

must also be specified and the<br />

named file must exist.<br />

'NEW' Create a new file. FILE= must<br />

also be specified and the named<br />

file must not exist.<br />

'UNKNOWN' If the file named in FILE=<br />

exists, open it with the status of<br />

OLD; ifitdoesnotexist,openit<br />

with the status of NEW. Thisis<br />

the default status.<br />

Chapter 10 379

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!