本文介绍了将Number转换为Words时,它不会得到十进制值.50的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
请指南,
而不是打印
总计1897.20
金额C $一千八百九十七和20/100仅
打印为
总计1897.20
金额C只需一千八百九十七和二百二十元
我的代码如下
Please Guide,
Instead of printing
total 1897.20
Amounts in words C$ One Thousand Eight Hundred Ninety Seven and 20/100 Only
Its print as
total 1897.20
Amounts in words C$ One Thousand Eight Hundred Ninety Seven and 2/100 Only
My Code below
string amountInWords(string number)
{
NumberToEnglish num = new NumberToEnglish();
return num.convertNumber (number);
}
if (rd1[3].ToString() == "INR")
{
if (inr.Paisa == "")
invoices.AmountWords = "Rupees " + inr.Rupees + " Only";
else
invoices.AmountWords = "Rupees " + inr.Rupees + " Paise " + inr.Paisa + " Only";
}
invoices.AmountWords = AddNewLineChar(invoices.AmountWords, 80);
conn.Close();
return invoices;
}
请告诉我我遇到的地方
Please Gide me Where i have stuck
推荐答案
string amountInWords(string number)
{
NumberToEnglish num = new NumberToEnglish();
return num.convertNumber (number);
}
if (rd1[3].ToString() == "INR")
{
if (inr.Paisa == "")
invoices.AmountWords = "Rupees " + inr.Rupees + " Only";
else
invoices.AmountWords = "Rupees " + inr.Rupees + " Paise " + inr.Paisa + " Only";
}
invoices.AmountWords = AddNewLineChar(invoices.AmountWords, 80);
conn.Close();
return invoices;
}
请告诉我我遇到的情况
Please Gide me Where i have stuck
这篇关于将Number转换为Words时,它不会得到十进制值.50的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!