Error in WordFind ?
Hello all,
i have a strange problem occuring here, i use the following code to count how many times a String appears in a another String (seperated by ,). But for some reason its counted wrong BCDE are definitely only contained once!
Var /Global LicenseFeatures
Var /Global TESTA
Var /Global TESTB
Var /Global TESTC
Var /Global TESTD
Var /Global TESTE
Var /Global TESTF
Section TEST
StrCpy $LicenseFeatures "A,B,C,D,E,F"
${WordFind} "$LicenseFeatures" "A" "#" $TESTA
${WordFind} "$LicenseFeatures" "B" "#" $TESTB
${WordFind} "$LicenseFeatures" "C" "#" $TESTC
${WordFind} "$LicenseFeatures" "D" "#" $TESTD
${WordFind} "$LicenseFeatures" "E" "#" $TESTE
${WordFind} "$LicenseFeatures" "F" "#" $TESTF
MessageBox MB_OK "LicenseFeatures: $LicenseFeatures $\r$\n \
A: $TESTA $\r$\n \
B: $TESTB $\r$\n \
C: $TESTC $\r$\n \
D: $TESTD $\r$\n \
E: $TESTE $\r$\n \
F: $TESTF $\r$\n"
SectionEnd
the result is:
LicenseFeatures: A,B,C,D,E,F
A: 1
B: 2
C: 2
D: 2
E: 2
F: 1
Any Ideas?