在delphi中,操作UNICODE字符串用那些函数?

解决方案 »

  1.   

    在高版本的Delphi中,字符串函数自动分辩类型,大都能支持UNICODE。 
      

  2.   

    delphi2006以前的用带有wide-前缀的字符串函数,2009以后的用字符串函数就行了。
      

  3.   

    AnsiToUtf8 functionConverts a string encoded in Ansi to UTF-8.PUCS4Chars functionConverts a UCS4 string to a null-terminated array of UCS4 characters.StringToWideChar functionReturns a UNICODE string from an AnsiString.UCS4StringToWideString functionConverts a string of 4-byte Unicode characters into a WideString value.UnicodeToUtf8 functionConverts a string of Unicode characters into a UTF-8 string.UTF8Decode functionConverts a UTF8 string to a Unicode string (WideString).UTF8Encode functionConverts a WideString value to a UTF8 string.Utf8ToAnsi functionConverts a UTF8 string to a string of Ansi characters.Utf8ToUnicode functionConverts a string of UTF-8 characters to a Unicode string.WideCharLenToString functionConverts Unicode characters to single or multi byte character data.WideCharLenToStrVar procedureWideCharLenToStrVar converts Unicode characters to single or multi byte character data.WideCharToString functionConverts null-terminated Unicode string to single or multi byte character data.WideCharToStrVar procedureConverts Unicode string to a single or multi byte character data.WideStringToUCS4String functionConverts a WideString value to a string of 4-byte Unicode characters.