| 比如: “2011年6月4日” 转换成 “二零一一年六月四日”。 我写了一个方法实现,但是感觉有点长
 
 复制代码static void Main(string[] args)
        {
            Console.WriteLine("2014年3月24日转换成{0}", GetStr("2014年3月24日"));
            Console.ReadKey();
        }
        public static string GetStr(string strNum)
        {
            //获得字符串数组
            char[] cList = strNum.ToCharArray();
            string Str;
            //定义数字数组
            int[] numList = new int[10] { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 };
            //定义中文数组
            string[] strList = new string[10] { "零", "一", "二", "三", "四", "五", "六", "七", "八", "九" };
            //通过循环对比,替换数字为相对应的中文
            for (int i = 0; i < cList.Length; i++)
            {
                for (int j = 0; j < numList.Length; j++)
                {
                    if (cList[i].ToString() == numList[j].ToString())
                    {
                        cList[i] = strList[j].ToCharArray()[0];
                    }
                }
            }
            //把char类型数组转换成string类型
            Str = new string(cList);
            return Str;
        }
 |