[Laszlo-user] string to bytes

Mo mail at mo.virtual-bunker.de
Fri Mar 3 13:47:31 EST 2006


Hoi,

is there a quick way of getting the size (in bytes) of an utf-8 encoded 
string?

If I call String.length I get the count of characters (of course) but 
not the number of bytes (e.g. the german 'ö' uses 2 bytes instead of 
only 1) and I don't want to check each character myself...

I'll keep looking for a solution, but if someone has an idea, let me know :)

Thanks for reading, greetings!
- Mo


More information about the Laszlo-user mailing list