You don't need the AnsiToUTF8 if you encode your source file as UTF-8 without a BOM.
Well, I installed and started Lazarus in the standard way so why isn't it using UTF-8 by default if that's the only way to store strings? Why let the user step into this trap? And how do I change my current code to UTF-8?
The difference from Delphi is caused by Lazarus supporting unicode and also some limitations of Free Pascal, but nothing which prevents the correct development of unicode apps if you follow the documentation: http://wiki.lazarus.freepascal.org/LCL_Unicode_Support
Thanks for the link. But why isn't it documented in the Help of TListBox? No word there that the strings may be UTF-8 only (and that you somehow have to store your code files in that coding if you use stings constants).
Delphi 7 doesn't support unicode, so I doubt you were using unicode routines there. Isn't that correct?
Yes, of course that's correct. That's the reason I didn't use Unicode for Lazarus either. But that failed. So I had a hard time to find out myself that I have to use AnsiToUTF8 for each and every constant string I use. A quite distracting first contact with Lazarus/FPC.
Jürgen Hestermann. _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal