最近跟编码干上了,一团乱,哪位高手指点一下,gb18030编码怎么才能转成unicode编码,我的开发环境是delphi2009,感觉WideCharToMultiByte函数和MultiByteToWideChar函数能实现,但是不知道咋用

解决方案 »

  1.   

    2009有一個:for Example: 
    TEncoding.UTF8.GetEncoding(936).GetString(v) 
      

  2.   

    我试了一下,getencodeing后面没有getstring这个方法
      

  3.   

    你是不是装了控件了,我就是照你说的做的,然后报下面的错
    E2250 There is no overloaded version of 'GetString' that can be called with these arguments
      

  4.   

    完全是copy你的代码
    s:=TEncoding.UTF8.GetEncoding(936).GetString(edit1.Text);
      

  5.   

    用TStringStream实现内码的转换了,2009下这个类型还是比较灵活的
      

  6.   

    看我的博客让《Windows系统和应用程序使用GB18030》一文。