Sharp PC-1500A User Manual Page 9

  • Download
  • Add to my manuals
  • Print
  • Page
    / 10
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 8
Example with a sequential
file
******************************
a)
0pen a new sequential
file
OPEN 2,8,5,
"Testl
.DAT,S,l'l"
If the OPEN is successfull, the
red LED will stay switched on.
b)
Print
the 0PEN-variable
PRrNT
DSHol'l$ 2
"
8,
S,Test1.DAT
,S,W
0"
c)
Write
data to
Testl.DAT
T$="SHARP
PC-l500"
:DIM
N(5)
:N(3)=t
/Z
PRINT
tl-15,2,"TRAMsoft",12345,T$, N(3)
d) Close the file
Testl.DAT
closE
2
The
data temporary stored in the memory of the floppy
is now written
to
the disk and the
red LED is
turned off.
e) 0pen
the
file Testl.DAT
for read
OPEN 0,8, 12,
"Test1
.DAT,S,R"
The
red LED is switched
on again.
f) Read data from
the file
Testl.DAT
into variables
INPUT
/t-15,0,A$,8$,C$,D$
or
INPUT
/I-15,0,A,8,C,D
0n disk, data
is stored
as
a string,
so
it
can be read always into string
variables. If
data is read
into num.
variables, a VAL operation is
per-
formed. If
there is no
translation into numerical
value
possible,
the
result is
zero.
There
will
never
an
ERROR
occure.
16/09/85 TRAMsoft
PF-8
e
Page view 8
1 2 3 4 5 6 7 8 9 10

Comments to this Manuals

No comments