永发信息网

762.56在Excel中如何将其变成大写金额

答案:3  悬赏:80  手机版
解决时间 2021-11-27 22:36
  • 提问者网友:相思似海深
  • 2021-11-27 03:41
762.56在Excel中如何将其变成大写金额
最佳答案
  • 五星知识达人网友:第四晚心情
  • 2021-11-27 04:21
下列的函数是我经常使用,C25单元格是数字,你只需要修改一下成为你想要的单元格即可!
=IF(ROUND(C25,2)<0,"无效数值",IF(ROUND(C25,2)=0,"零",IF(ROUND(C25,2)<1,"",TEXT(INT(ROUND(C25,2)),"[dbnum2]")&"元")&IF(INT(ROUND(C25,2)*10)-INT(ROUND(C25,2))*10=0,IF(INT(ROUND(C25,2))*(INT(ROUND(C25,2)*100)-INT(ROUND(C25,2)*10)*10)=0,"","零"),TEXT(INT(ROUND(C25,2)*10)-INT(ROUND(C25,2))*10,"[dbnum2]")&"角")&IF((INT(ROUND(C25,2)*100)-INT(ROUND(C25,2)*10)*10)=0,"整",TEXT((INT(ROUND(C25,2)*100)-INT(ROUND(C25,2)*10)*10),"[dbnum2]")&"分")))
全部回答
  • 1楼网友:时间的尘埃
  • 2021-11-27 06:39
右键-设置单元格格式-数字-特殊- 中文大写数字 OK
  • 2楼网友:往事隔山水
  • 2021-11-27 05:32
我可以给你一段代码。。。运行下就行。。。

Function 大写(CELL As String) As String
Dim RMBS As String
If CELL = "" Or Not IsNumeric(CELL) Then 大写 = "": Exit Function
If CELL = 0 Then 大写 = "零元整": Exit Function
RMBS = Replace(Replace(Application.Text(Round(CELL, 2), "[DBnum2]"), ".", "元"), "-", "负")
RMBS = IIf(Left(Right(RMBS, 3), 1) = "元", Left(RMBS, Len(RMBS) - 1) & "角" & Right(RMBS, 1) & "分", IIf(Left(Right(RMBS, 2), 1) = "元", RMBS & "角", IIf(RMBS = "零", "", RMBS & "元整")))
RMBS = Replace(Replace(RMBS, "零元", ""), "零角", "")
大写 = RMBS

End Function
我要举报
如以上回答内容为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
点此我要举报以上问答信息
大家都在看
推荐资讯