CLOSESEQ

CLOSESEQ

Top  Previous  Next

 

The CLOSESEQ statement closes an item previously opened using OPENSEQ.

 

 

Format

 

CLOSESEQ file.var {ON ERROR statement(s)}

 

where

 

file.varis the file variable previously associated with the directory file record or device by use of the OPENSEQ statement.

 

statement(s)are statement(s) to be executed if the close action fails.

 

 

The directory file record or device is closed and file.var is converted to integer zero.

 

The ON ERROR clause is provided for source program compatibility with other systems and will never be executed by QMBasic programs.

 

The CLOSESEQ and CLOSE statements can be interchanged without adverse effect in QMBasic programs, however, care should be taken to use the correct statement if portability to other systems is required.

 

 

Example

 

CLOSESEQ STOCK.LIST

 

This statement closes a directory file record previously opened using OPENSEQ and associating it with STOCK.LIST as the file variable.

 

 

See also:

CREATE, NOBUF, OPENSEQ, READBLK, READSEQ, SEEK, WEOFSEQ WRITEBLK, WRITESEQ, WRITESEQF