在word中,如果输入的公式太长,一行显示不下,如何实现换行?如下面例子:
=IF(B1<0,"金额为负无效",(IF(OR(B1=0,B1=""),"(人民币)零元",IF(B1<1,"(人民币)",
TEXT(INT(B1),"[dbnum2](人民币)G/通用格式")&"元F"))))&IF((INT(B1*10)-INT(B1)*10)=0,
IF(INT(B1*100)-INT(B1*10)*10=0,"","零"),(TEXT(INT(B1*10)-INT(B1)*10,"[dbnum2]")&"角"))
&IF((INT(B1*100)-INT(B1*10)*10)=0,"整",TEXT((INT(B1*100)-INT(B1*10)*10),"[dbnum2]")&"分")
可以按“Shift键 + 回车键”完成换行功能,上面例子变为:。
="大写金额:"&IF(TRIM(B1)="","",IF(B1=0,"","人民币"&IF(B1<0,"负
",)&IF(INT(B1),TEXT(INT(ABS(B1)),"[dbnum2]")&"元
",)&IF(INT(ABS(B1)*10)-INT(ABS(B1))*10,TEXT(INT(ABS(B1)*10)-INT(ABS(B1))*10,"[d
bnum2]")&"角",IF(INT(ABS(B1))=ABS(B1),,IF(ABS(B1)<0.1,,"零
")))&IF(ROUND(ABS(B1)*100-INT(ABS(B1)*10)*10,),TEXT(ROUND(ABS(B1)*100-INT(ABS(B1)*10)*10,),"[dbnum2]")&"分","整")))