问题补充说明: 比如 a1单元格中的数字:1203002.02 在f17中 转换为 壹佰贰拾万零叁仟零贰元零贰分 我现有的公式 =IF(F17=0,"",(TEXT(ROUNDDOWN(F17,0),"[DBNum2]")&"元"&IF(ROUNDDOWN(F17,0)=F17,"整",IF(ROUNDDOWN(F17*10,0)=F17*10,TEXT(RIGHT(F17*10,1),"[DBNum2]")&"角整",IF(ROUNDDOWN(F17*10,0)=ROUNDDOWN(F17,0)*10,"零"&TEXT(RIGHT(F17*100,1),"[DBNum2]")&"分",TEXT(RIGHT(ROUNDDOWN(F17*10,0),1),"[DBNum2]")&"角"&TEXT(RIGHT(F17*100,1),"[DBNum2]")&"分")))))只能转成 壹佰贰拾万叁仟零贰元零贰分请高手指教
我有一个自定义函数,你看看合用不?
Function大写(m)
大写=IIf(m="","",IIf(m>-0.005,"","负")&IIf(Abs(m)+0.005<1,"","计"&Application.Text(Int(Round(Abs(m),2)),"[D洋获重单音论剧病低Bnum2]")&"元")&Application.Text(Right(10酸威渐部0*Round(m,2),2),"[dbnum2]0角0分"))
大写=Replace(Replace(大写,"零角",IIf(Ab派传报态应面久满银念s(m)>1AndRight(Round(100*m,0),1),"零","")),"零分",IIf(Round(m,2),"整",""))
EndFunction
如果你不会用,给我留言
标签:excel,小写,大写