Formatting and I/O Library Chapter 2
LabWindows/CVI Standard Libraries 2-8 © National Instruments Corporation
Return Value
result integer Result of the compare
operation.
Return Codes
-1 Bytes from buffer#1 less than bytes from buffer#2.
0 Bytes from buffer#1 identical to bytes from buffer#2.
1 Bytes from buffer#1 greater than bytes from
buffer#2.
Parameter Discussion
Both buffer#1Index and buffer#2Index are zero-based.
If caseSensitive is zero, alphabetic characters are compared without regard to case. If
caseSensitive is non-zero, alphabetic characters are considered equal only if they have the same
case.
The function returns an integer value indicating the lexicographic relationship between the two
sets of bytes.
CompareStringsint result = CompareStrings (char *string#1, int string#1Index, char *string#2,
int string#2Index, int caseSensitive);
Purpose
Compares the NUL-terminated string starting at position string#1Index of string#1 to the
NUL-terminated string starting at position string#2Index of string#2. Both string#1Index and
string#2Index are zero-based.
Parameters
Input string#1 string String 1.
string#1Index integer Starting position in string#1.
string#2 string String 2.
string#2Index integer Starting position in string#2.
caseSensitive integer Case sensitivity mode.