[Lazarus] Unicode support enabled for win32 with fpc 2.2.1 and higher

Lee Jenkins lee at datatrakpos.com
Sun Apr 20 19:39:34 CEST 2008


Lee Jenkins wrote:
> Felipe Monteiro de Carvalho wrote:
>> On Fri, Apr 18, 2008 at 7:11 PM, Lee Jenkins <lee at datatrakpos.com> wrote:
>>>  Sorry to be so ignorant on the subject, are you saying the calls to RTL
>>>  fileutils need to have the "strings" cast to UTF-8 somehow?
>> I just made a small wiki guide:
>>
>> http://wiki.lazarus.freepascal.org/LCL_Unicode_Support#Instructions_for_users
>>
> 
> Excellent entry, Felipe.  Just to be sure that I am not off base, the following 
> would have to the case?
> 
> var
>    lString1, lString2: string;
>    lDate: TDateTime;
> begin
>    lDate := Now;
>    lString1 := 'My %s string';
>    lString2 := Format(UTF8ToAnsi(lString1), UTF8ToAnsi('Sample'));
> end;

Sorry, missed the brackets in format function:

lString2 := Format(UTF8ToAnsi(lString1), [UTF8ToAnsi('Sample')]);


-- 

Warm Regards,

Lee

"When my company started out, we were really, really, really, really small. 
Now...we're just really small."



More information about the Lazarus mailing list