strCmp Function
Use
Purpose
Compares two strings for equality (case-sensitive).
Syntax
int strCmp (in string string1, in string string2)
Parameters
|
string1 |
Expression evaluating to a string. |
|
string2 |
Expression evaluating to a string. |
Description
This function compares two strings.
Writing `a == b` is equivalent to calling `strCmp (a, b)`.
Return Value
|
Condition |
Return Value |
|
If string1 is equal to string2. |
0 |
|
If string1 is less than string2. |
<0 |
|
If string2 is less than string1. |
>0 |
Example
`if (strCmp(toLower(~language), "en") == 0)` English Version: `end`