Remarks, Var arrayr, String or var – Campbell Scientific CR9000X Measurement and Control System User Manual
Page 404

Section 11. String Functions
SplitStr (ResultString, SearchString, FilterString, NumSplit, SplitOption)
The SplitStr instruction is used to return an array of strings or numerics from a
search string.
Syntax
SplitStr ( ResultString, SearchString, FilterString, NumSplit, SplitOption )
Remarks
The FilterString and SplitOption help to define the array returned by the
SplitStr instruction.
Parameter
& Data Type
Enter
SPLITSTR PARAMETERS
SplitResult
Var Arrayr
The SplitResult parameter is an array in which the split string will be stored.
SearchStr
String or Var
The string on which this instruction will operate.
FilterString
String or Var
Used to provide a filter for the string(s) to be returned. For a FilterString
using non-printable ASCII characters, use the CHR function and the
appropriate ASCII code
NumeSplit
Constant
Used to define the maximum number of strings or values returned by the
instruction.
SplitOption
Constant
The SplitOption parameter is a code used to specify the method of splitting
the string:
0
NUMERIC SearchString is parsed based upon the occurrence of a
number in the string (delimiters are + - . 0 1 2 3 4 5 6 7 8 9 0 E). The
numeric value is stored in the array; other characters are discarded. With
this option, FilterString is ignored.
1
NON-NUMERIC - SearchString is parsed based upon the occurrence of
non-numeric characters in the string (delimiters are any character but + -
. 0 1 2 3 4 5 6 7 8 9 0). The non-numeric characters are stored in the
array; numeric characters are discarded. FilterString is ignored.
2
SEARCHSTRING - SearchString is parsed based upon the occurrence
of the entire FilterString.
3
SEARCHCHARS - SearchString is parsed based upon each occurrence
of any character that is in FilterString
4
HEADERFILTER - Any strings succeeding FilterString are returned.
5
FOOTERFILTER - Any strings preceding FilterString are returned.
6
HEADERFILTERCHARS - Strings succeeding any character in the
FilterString char list are returned in SplitResult.
7
FOOTERFILTERCHARS
-
Strings
preceding any character in the
FilterString char list are returned in SplitResult
8
NUMERICHEX - SearchString is parsed based upon the occurrence of
hexadecimal numerics in the string (delimiters are any character but 0 1
2 3 4 5 6 7 8 9 0 A B C D E F). The hexadecimal value is stored in the
array. With this option, FilterString is ignored.
1X Where X is one of the options above, right justify the resultant array,
filling vacant elements with NAN (if numeric) or a NULL string if a
string.
.
11-8