• 回答数

    7

  • 浏览数

    116

赵鹏飞1976
首页 > 英语培训 > 数字转换英文大写

7个回答 默认排序
  • 默认排序
  • 按时间排序

夏天天夏天

已采纳

转中文大写:="大写人民币"&SUBSTITUTE(SUBSTITUTE(IF(-RMB(A1,2),TEXT(A1,";负")&TEXT(INT(ABS(A1)+0.5%),"[dbnum2]G/通用格式圆;;")&TEXT(RIGHT(RMB(A1,2),2),"[dbnum2]0角0分;;整"),),"零角",IF(A1^2<1,,"零")),"零分","整")

转英文大写:

先alt+f11, 打开vba, 插入模块,复制下面代码->粘贴,

Function SpellNumber(ByVal MyNumber)

Dim Dollars, Cents, Temp

Dim DecimalPlace, Count

ReDim Place(9) As String

Place(2) = " Thousand "

Place(3) = " Million "

Place(4) = " Billion "

Place(5) = " Trillion "

' String representation of amount.

MyNumber = Trim(Str(MyNumber))

' Position of decimal place 0 if none.

DecimalPlace = InStr(MyNumber, ".")

' Convert cents and set MyNumber to dollar amount.

If DecimalPlace > 0 Then

Cents = GetTens(Left(Mid(MyNumber, DecimalPlace + 1) & _

"00", 2))

MyNumber = Trim(Left(MyNumber, DecimalPlace - 1))

End If

Count = 1

Do While MyNumber <> ""

Temp = GetHundreds(Right(MyNumber, 3))

If Temp <> "" Then Dollars = Temp & Place(Count) & Dollars

If Len(MyNumber) > 3 Then

MyNumber = Left(MyNumber, Len(MyNumber) - 3)

Else

MyNumber = ""

End If

Count = Count + 1

Loop

Select Case Dollars

Case ""

Dollars = " DOLLARS"

Case "One"

Dollars = " DOLLAR"

Case Else

Dollars = Dollars & " DOLLARS"

End Select

Select Case Cents

Case ""

Cents = " ONLY."

Case "One"

Cents = " and One Cent ONLY."

Case Else

Cents = " and " & Cents & " Cents ONLY."

End Select

SpellNumber = Dollars & Cents

End Function

' Converts a number from 100-999 into text

Function GetHundreds(ByVal MyNumber)

Dim Result As String

If Val(MyNumber) = 0 Then Exit Function

MyNumber = Right("000" & MyNumber, 3)

' Convert the hundreds place.

If Mid(MyNumber, 1, 1) <> "0" Then

Result = GetDigit(Mid(MyNumber, 1, 1)) & " Hundred "

End If

' Convert the tens and ones place.

If Mid(MyNumber, 2, 1) <> "0" Then

Result = Result & GetTens(Mid(MyNumber, 2))

Else

Result = Result & GetDigit(Mid(MyNumber, 3))

End If

GetHundreds = Result

End Function

' Converts a number from 10 to 99 into text.

Function GetTens(TensText)

Dim Result As String

Result = ""           ' Null out the temporary function value.

If Val(Left(TensText, 1)) = 1 Then   ' If value between 10-19...

Select Case Val(TensText)

Case 10: Result = "Ten"

Case 11: Result = "Eleven"

Case 12: Result = "Twelve"

Case 13: Result = "Thirteen"

Case 14: Result = "Fourteen"

Case 15: Result = "Fifteen"

Case 16: Result = "Sixteen"

Case 17: Result = "Seventeen"

Case 18: Result = "Eighteen"

Case 19: Result = "Nineteen"

Case Else

End Select

Else                                 ' If value between 20-99...

Select Case Val(Left(TensText, 1))

Case 2: Result = "Twenty "

Case 3: Result = "Thirty "

Case 4: Result = "Forty "

Case 5: Result = "Fifty "

Case 6: Result = "Sixty "

Case 7: Result = "Seventy "

Case 8: Result = "Eighty "

Case 9: Result = "Ninety "

Case Else

End Select

Result = Result & GetDigit _

(Right(TensText, 1))  ' Retrieve ones place.

End If

GetTens = Result

End Function

' Converts a number from 1 to 9 into text.

Function GetDigit(Digit)

Select Case Val(Digit)

Case 1: GetDigit = "One"

Case 2: GetDigit = "Two"

Case 3: GetDigit = "Three"

Case 4: GetDigit = "Four"

Case 5: GetDigit = "Five"

Case 6: GetDigit = "Six"

Case 7: GetDigit = "Seven"

Case 8: GetDigit = "Eight"

Case 9: GetDigit = "Nine"

Case Else: GetDigit = ""

End Select

End Function

改良公式:=UPPER("say "&SpellNumber(A1))

附件:中英文数字金额转大写 (注意:有宏:))

网页链接

数字转换英文大写

340 评论(15)

AlpacaZhou

Excel中利用numberstring公式将阿拉伯数字转换为大写数字

349 评论(12)

Romy莎莎mei

数字翻译成英文如下number例句我不会太相信这些数字的。I wouldn't place too much reliance on these figures.在你的计算中把这些数字作为近似参考数值。Use these figures as an approximate guide in your calculations.

352 评论(12)

一帆杰作

数字翻译成英文大写是:NUMBERnumber[ˈnʌmbə(r)]n. 数字;电话号码;编号,序数;数量双语例句What's your mobile number? 你的手机号码是多少?

185 评论(9)

飞翔的等待

数字翻译成英文大写:NUMBERnumber英 [ˈnʌmbə(r)] 美 [ˈnʌmbər] n. 数字;电话号码;编号,序数;总量,数量;数量众多的人(或物);(杂志的)一期;一群人;(演出中的)一首歌,一段舞蹈;<非正式>吸引人的人(或事物);数,单复数;收视率,收听率;(运动员等的)历史数据;钱数;具有……特征的人;常说的事;数字彩票;算术v. 给……编号;总计;包括,列入(某类);计算,数;使为数有限

161 评论(9)

冬日红葉

操作步骤:

1、在输入数字前先输入“V”;

2、紧接着输入要变大写的数字;

3、现在按下b键即可输入大写数字了。

182 评论(15)

yanran8385

这个需要VB代码:你需要复制代码——在EXCEL中按ALT+F11——插入——模块——粘贴代码——然后就可以使用函数Spellnumber了。

如:=Spellnumber(A1)

230 评论(9)

相关问答