Hello Arno
Thanks your comments. I need update my head from ansi to unicode :-)
Should not be problem, or that I think, converting unicode encoded files to ansi. as all files will created on local network. I will read a bit more about differences between UTF8String and UnicodeString, help from BC2009 is not clear.

Xavi

Al 29/04/2010 08:54, En/na Arno Garrels ha escrit:
Xavier Mor-Mur wrote:

String usStr; (or UnicodeString usStr;)
AnsiString asStr;

usStr = URLDEcode( "Sin%20t%C3%ADtulo%201_html_m5b7e3440.jpg" );
asStr = usStr;<--- Compiler introduce required conversion code

using
       asStr = UTF8Decode( usStr );
or
      asSTR = UTF8Decode( URLDEcode(
"Sin%20t%C3%ADtulo%201_html_m5b7e3440.jpg" ) );
Conversion from Unicode to AnsiString might lead to dataloss,
whether the source be UTF-8 or UTF-16. If you actually need a
AnsiString with code page CP_UTF8 you should use type UTF8String
instead of AnsiString.
Since 2009 the compiler is code page aware and implicitly
converts between UTF8String and (Unicode)String without
dataloss and warnings. In this case one could also write a
slighty different version of UrlDecode() that returned a
UTF8String to save a few conversions.

--
Arno Garrels

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be



Se certifico que el correo entrante no contiene virus.
Comprobada por AVG - www.avg.es
Version: 9.0.814 / Base de datos de virus: 271.1.1/2840 - Fecha de la version: 
04/28/10 08:27:00


--
Xavier Mor-Mur

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to