HP 3000 Manuals

WRD [ HP Business BASIC/XL Reference Manual ] MPE/iX 5.0 Documentation


HP Business BASIC/XL Reference Manual

WRD 

The WRD function returns the number of the word indicated by the file's
word pointer.  The result is of type INTEGER.

Syntax 

WRD(fnum)

Parameters 

fnum             The file number by which HP Business BASIC/XL identifies
                 the file.  It is a numeric expression that evaluates to
                 a positive short integer.  Fnum must specify a BASIC
                 DATA file.  An optional # can precede fnum.

Examples 

     10 CREATE "File1",RECSIZE=5,FILESIZE=10 !BDATA file; 10 5-wd recs.
     11 ASSIGN "File1" TO #1
     12 PRINT #1,9,2; 36            !Print 36 on record 9, word 2;
     13                             ! move pointer to word 3.
     14 PRINT #1,9,4; 567           !Print 567 on record 9, word 4;
     15                             ! move pointer to record 5.
     16 DISP WRD(#1)                !Display 5.
     17 PRINT #1,9,5; 98            !Print 98 on record 9, word 5;
     18                             ! move pointer to record 10, word 1
     19 DISP WRD(#1)                !Display 1.
     99 END



MPE/iX 5.0 Documentation