
Section 9. Program Control Instructions
9-6
Alternatively, the same thing can be accomplished by incorporating the range
test in the Do...Loop as follows:
Dim Reply
'Declare variable.
Do
Reply = Volt(1)
Loop Until Reply > 1 And Reply < 9
The next example show the use of Wend.
While X > Y
'Old fashioned way of looping.
.........
.........
Wend
Do While X > Y
'Much better
.........
.........
Loop
FileManage
The FileManage instruction is used to manage files from within a running
datalogger program.
Syntax
FileManage( "Device: FileName", Attribute )
Remarks
FileManage is a function that allows the active datalogger program to
manipulate program files that are stored in the datalogger.
The FileManage instruction has the following parameters:
Parameter
& Data Type
Enter
Device;
Filename
Text
The "Device:Filename" argument is the file that should be manipulated. The
Device on which the file is stored must be specified and the entire string
must be enclosed in quotation marks. Device = CPU, the file is stored in
datalogger memory. Device = CRD, the file is stored on a PCMCIA card..
Attribute
Constant
The Attribute is a numeric code to determine what should happen to the file
affected by the FileManage instruction. The Attribute codes are actually a
bit field. The codes are as follows:
Bit
Decimal
Description
bit 0
1
Program not active
bit 1
2
Run on power up
bit 2
4
Run now
bits 1 & 2
6
Run now and on power up
bit 3
8
Delete
bit 4
16
Delete all
Summary of Contents for CR5000
Page 40: ...Section 1 Installation and Maintenance 1 16 This is a blank page ...
Page 54: ...Section 2 Data Storage and Retrieval 2 14 This is a blank page ...
Page 88: ...Section 4 CRBasic Native Language Programming 4 12 This is a blank page ...
Page 94: ...Section 5 Program Declarations 5 6 This is a blank page ...
Page 172: ...Section 7 Measurement Instructions 7 46 This is a blank page ...
Page 206: ......
Page 236: ...Index Index 4 This is a blank page ...
Page 237: ...This is a blank page ...