首页 新闻 会员 周边

C# 文字转UTF-8编码

0
悬赏园豆:10 [已关闭问题] 关闭于 2017-07-09 12:45

C# 文字转UTF-8编码

实现如下链接功能:

http://tool.chinaz.com/tools/utf-8.aspx

妖狐鬼魅的主页 妖狐鬼魅 | 初学一级 | 园豆:92
提问于:2017-06-29 19:15
< >
分享
所有回答(1)
-1

参考:http://www.cnblogs.com/xiaofengfeng/archive/2011/12/23/2299679.html

public static    string  get_uft8(string unicodeString)
        {
            UTF8Encoding utf8 = new UTF8Encoding();
            Byte[] encodedBytes = utf8.GetBytes(unicodeString);
            String decodedString = utf8.GetString(encodedBytes);
            return decodedString;
        }
开山怪不怪 | 园豆:544 (小虾三级) | 2017-06-29 23:07

没用,C#调用C dll 在C代码层不生效。

支持(0) 反对(0) Yanshing Hwang | 园豆:200 (初学一级) | 2021-11-15 11:44
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册