Exemplo n.º 1
0
        /// <summary>
        /// 数字转换为一二三...九
        /// </summary>
        /// <param name="value">原始值</param>
        /// <returns>转换后值</returns>
        private string UpperNumber1(string value)
        {
            if (!string.IsNullOrEmpty(value))
            {
                DigitToChineseText obj = new DigitToChineseText();
                return obj.Convert(value, false);
            }

            return string.Empty;
        }
Exemplo n.º 2
0
        /// <summary>
        /// 数字转换为零、壹、贰、叁、肆、伍、陆、柒、捌、玖
        /// </summary>
        /// <param name="value">原始值</param>
        /// <returns>转换后值</returns>
        private string UpperNumber2(string value)
        {
            if (this.IsThousand)
            {
                return this.Number(value);
            }
            else
            {
                if (!string.IsNullOrEmpty(value))
                {
                    DigitToChineseText obj = new DigitToChineseText();
                    return obj.Convert(value, true);
                }
            }

            return string.Empty;
        }