Findstring case insensitive bug(?)
Posted: Thu Apr 10, 2014 1:55 am
Maybe my brain isn't working as it should, but:
Tested under Windows 8.1 64-bit with PB 5.10(x86 compiler), 5.22 (unicode/ascii/x86/x64) same result.
Never used findstring alot in the past, and now I only need it for a small personal project so coding a horrible slow replacement procedure will work.
But I would like to know if I'm just doing it wrong or if it's a bug. Thanks.
OT: my sig should really be updated!
But the result doesn't match my expectations:Changes in PB 5.10
- Added: #PB_String_NoCase mode parameter to FindString()
Code: Select all
Debug FindString("The quick brown fox jumps over the lazy dog","brown",#PB_String_CaseSensitive)
;Default mode. Returns 11 as it should.
Debug FindString("The quick brown fox jumps over the lazy dog","Brown",#PB_String_NoCase)
;Case insensitive so should return 11 (B=b). Returns 0
Never used findstring alot in the past, and now I only need it for a small personal project so coding a horrible slow replacement procedure will work.
But I would like to know if I'm just doing it wrong or if it's a bug. Thanks.
OT: my sig should really be updated!
