02.07.2013 Views

HP Fortran Programmer's Reference

HP Fortran Programmer's Reference

HP Fortran Programmer's Reference

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

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

REWIND<br />

REWIND<br />

Positions file at its initial point.<br />

Syntax<br />

The syntax of the REWIND statement can take one of the following forms:<br />

420<br />

Short form:<br />

integer-expression<br />

Long form:<br />

REWIND (io-specifier-list)<br />

integer-expression<br />

io-specifier-list<br />

[UNIT=]unit<br />

ERR=stmt-label<br />

IOSTAT=integer-variable<br />

Description<br />

is the unit connected to a sequential file or device.<br />

is a list of the following comma-separated I/O specifiers:<br />

specifies the unit connected to an external file opened for sequential access.<br />

unit must be an integer expression that evaluates to a number greater than<br />

0. If the optional keyword UNIT= is omitted, unit must be the first item in<br />

io-specifier-list.<br />

specifies the label of the executable statement to which control passes if an<br />

error occurs during statement execution.<br />

returns the I/O status after the statement executes. If the statement<br />

executes successfully, integer-variable is set to zero. If an error occurs, it<br />

is set to a positive integer that indicates which error occurred.<br />

The REWIND statement repositions the file connected to the specified unit at the start of the<br />

first record. If the file is already at its starting point or if the unit is not connected to a file, the<br />

REWIND statement has no effect.<br />

Chapter 10

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

Saved successfully!

Ooh no, something went wrong!