11.04.2013 Views

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

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.

OSCLOSE<br />

Syntax<br />

OSCLOSE file.var [ON ERROR statements]<br />

Description<br />

The <strong>UniBasic</strong> OSCLOSE command closes a sequential file that you opened with the<br />

OSOPEN or OPENSEQ command.<br />

Parameters<br />

The following table describes each parameter of the syntax.<br />

Parameter Description<br />

file.var Specifies the file to close.<br />

ON ERROR<br />

statements<br />

Specifies statements to execute if the OSCLOSE statement fails with a<br />

fatal error because the file is not open, an I/O error occurs, or UniData<br />

cannot find the file.<br />

If you do not specify the ON ERROR clause and a fatal error occurs, the<br />

program terminates.<br />

OSCLOSE Parameters<br />

STATUS Function Return Values<br />

After you execute OSCLOSE, the STATUS function returns one of the values<br />

described in the following table.<br />

Value Description<br />

0 The file is closed successfully.<br />

5 The file did not close.<br />

STATUS Function Return Values<br />

OSCLOSE 1-554

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

Saved successfully!

Ooh no, something went wrong!