SplitStr does not accept scandinavian special alphabets

Report any Hollywood bugs here
Post Reply
Bugala
Posts: 1178
Joined: Sun Feb 14, 2010 7:11 pm

SplitStr does not accept scandinavian special alphabets

Post by Bugala »

array, c = SplitStr("AmigaOS3öMorphOSöAmigaOS4öWarpOSöAROS", "ö")
For k = 1 To c Do NPrint(array[k - 1])

results in:

Error in line 1 (Unnamed2): Wrong usage/parameters for this command!
Read the documentation!
User avatar
airsoftsoftwair
Posts: 5443
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: SplitStr does not accept scandinavian special alphabets

Post by airsoftsoftwair »

Yes, this is a known limitation. SplitStr() currently needs a single byte as a separator and Scandinavian characters will be two bytes in UTF-8. As a workaround, you could switch to ISO 8859-1 mode. Then they should work.
User avatar
airsoftsoftwair
Posts: 5443
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: SplitStr does not accept scandinavian special alphabets

Post by airsoftsoftwair »

Code: Select all

- Fix: SplitStr() didn't work with UTF-8 characters that contained more than one byte
Post Reply