Displaying
List
of
Files
in
Current
Directory
This
program
displays
the
list
of
the
les
in
the
current
directory
.
d
a
c
b
10
!
20
!
Figure
11-9.
File
list
30
!
40
ASSIGN
@Hp4396
TO
717
50
OUTPUT
@Hp4396;"*rst"
60
!
70
Dir_instr(@Hp4396)
80
!
90
END
100
!
110
!
Dir_instr
120
!
130
SUB
Dir_instr(@Hp4396)
140
DIM
Stor_dev$[5],Curr_dir$[50],File_name$[13]
150
!
160
OUTPUT
@Hp4396;"STODMEMO?"
170
ENTER
@Hp4396;A
180
IF
A=1
THEN
190
Stor_dev$="MEMO"
200
ELSE
210
Stor_dev$="DISK"
220
END
IF
230
OUTPUT
@Hp4396;"CWD?"
240
ENTER
@Hp4396;Curr_dir$
250
"["&Stor_dev$&"]:
"&Curr_dir$
260
"Size[byte]
File
Name"
270
"------------------------"
280
OUTPUT
@Hp4396;"FNUM?"
290
ENTER
@Hp4396;File_count
300
IF
File_count>=1
THEN
310
FOR
I=1
TO
File_count
320
OUTPUT
@Hp4396;"FNAME?
";I
330
ENTER
@Hp4396;File_name$
340
OUTPUT
@Hp4396;"FSIZE?
"""&File_name$&""""
350
ENTER
@Hp4396;File_size
360
USING
"XX,DDDDDD,XXXX,K";File_size,File_name$
370
NEXT
I
380
END
IF
390
SUBEND
Figure
11-10.
Sample
Program:
Displaying
List
of
Files
in
Current
Directory
of
4396B
Line
70
calls
the
subprogram
to
display
the
list
of
the
les
in
the
current
directory
.
Lines
160
to
250
check
the
storage
device
currently
selected
and
its
current
directory
name
,
and
then
display
the
result.
Lines
280
to
290
check
the
number
of
the
les
in
the
current
directory
.
If
there
are
any
les
in
the
current
directory
,
lines
300
to
380
check
the
name
and
size
of
every
le
and
display
them.
Using
Application
Programs
11-15
Содержание Agilent 4396B
Страница 12: ...Tables A 1 Manual Changes by Serial Number A 1 A 2 Manual Changes by Firmware Version A 1 Contents 6 ...
Страница 32: ......
Страница 52: ......
Страница 68: ......
Страница 72: ......
Страница 92: ......
Страница 96: ......
Страница 99: ...Agilent 4396B Network Spectrum Impedance Analyzer Using Instrument BASIC with the 4396B Printed in JAPAN ...
Страница 100: ...c Copyright 1997 2000 2001 2003 Agilent Technologies Japan Ltd ...
Страница 116: ......
Страница 126: ......
Страница 130: ......
Страница 138: ......
Страница 148: ......
Страница 163: ...C The Keyboard Mini DIN keyboard is following key layout Figure C 1 mini DIN Keyboard The Keyboard C 1 ...
Страница 176: ......