Op 2010-10-21 08:29, Graeme Geldenhuys het geskryf: > > Length() returns number of bytes, not number of characters. The incorrect > assumption was made back in Delphi (before unicode support).
>From Delphi 7 & Kylix 3 help: "For single-byte and multibyte strings, Length returns the number of bytes used by the string. For Unicode (WideString) strings, Length returns the number of bytes divided by two." FPC help does not specify what the value is that Length() returns - bytes or characters. So I default to the Delphi/Kylix help. Regards, - Graeme - -- fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net:8080/fpgui/ _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal