613-518-1166 info@zimdatabases.com

ZIM Language Reference

SET EOFVALUE

< All Topics

Specifies an end-of-file indicator for application documents.

Syntax

SET EOFVALUE character_constant|OFF

Parameters

character_constant

Any valid character constant. If encountered during the read of an application document, the string raises an end-of-file condition.

Comments

The EOFVALUE option is set OFF by default (no character is recognized as an end-of-file).

The EOFVALUE option enables you to specify one or more characters that are to be recognized as an end-of-file indicator when the software reads an application document.

When reading input from the terminal as an application document, the software always recognizes a zero-length line as an end-of-file. The software also recognizes real end-of-file conditions, independent of the setting of EOFVALUE.

Example

set eofvalue “xyz”
add DataCollected from SerDevice
set eofvalue off
% batch complete – do something else

Assume that a device attached to your computer has been defined as an application document called SerDevice. The device is collecting data and sending it to your computer in batches that are terminated with a record containing the characters “xyz”. The above commands read the data without waiting between batches.

Was this article helpful?
0 out Of 5 Stars
5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 0%
How can we improve this article?
Table of Contents