UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software UniBasic Commands Reference - Rocket Software

rocketsoftware.com
from rocketsoftware.com More from this publisher
11.04.2013 Views

Related Commands UniBasic DIM, INMAT, MAT, MATBUILD, MATPARSE, MATREAD, MATREADL, MATWRITE, MATWRITEU UniData DEFAULT.LOCKED.ACTION – For information, see the UniData Commands Reference. 1-458 UniBasic Commands Reference

MATWRITE Syntax MATWRITE dim.array {ON | TO file.var,} record.ID.expr [ON ERROR statements] Description The UniBasic MATWRITE command writes successive elements of a dimensioned array to the corresponding attributes of a record. If the dimensioned array size exceeds the number of attributes in the target record, the MATWRITE command does not write the trailing spaces. If the 0 element is not empty, the command writes the contents of the element after the final element in the record (as element N+1). Note: This command must be preceded by MATREADU or another locking command to prevent the type of inconsistency that results when multiple users access files at the same time. For more information, see Developing UniBasic Applications. Parameters The following table describes each parameter of the syntax. Parameter Description dim.array Specifies the dimensioned array from which to assign the values read to the successive attributes of the record record.ID.expr. You must name and dimension an array before you can use it in the MATWRITE statement. MATWRITE Parameters MATWRITE 1-459

MATWRITE<br />

Syntax<br />

MATWRITE dim.array {ON | TO file.var,} record.ID.expr<br />

[ON ERROR statements]<br />

Description<br />

The <strong>UniBasic</strong> MATWRITE command writes successive elements of a dimensioned<br />

array to the corresponding attributes of a record.<br />

If the dimensioned array size exceeds the number of attributes in the target record,<br />

the MATWRITE command does not write the trailing spaces. If the 0 element is not<br />

empty, the command writes the contents of the element after the final element in the<br />

record (as element N+1).<br />

Note: This command must be preceded by MATREADU or another locking command<br />

to prevent the type of inconsistency that results when multiple users access files at the<br />

same time. For more information, see Developing <strong>UniBasic</strong> Applications.<br />

Parameters<br />

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

Parameter Description<br />

dim.array Specifies the dimensioned array from which to assign the values<br />

read to the successive attributes of the record record.ID.expr.<br />

You must name and dimension an array before you can use it in<br />

the MATWRITE statement.<br />

MATWRITE Parameters<br />

MATWRITE 1-459

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

Saved successfully!

Ooh no, something went wrong!