欧美色欧美亚洲高清在线观看,国产特黄特色a级在线视频,国产一区视频一区欧美,亚洲成a 人在线观看中文

  1. <ul id="fwlom"></ul>

    <object id="fwlom"></object>

    <span id="fwlom"></span><dfn id="fwlom"></dfn>

      <object id="fwlom"></object>

      EXCEL表格中將數(shù)字金額轉(zhuǎn)換為英文

      時(shí)間:2019-05-14 13:42:32下載本文作者:會(huì)員上傳
      簡(jiǎn)介:寫寫幫文庫小編為你整理了多篇相關(guān)的《EXCEL表格中將數(shù)字金額轉(zhuǎn)換為英文》,但愿對(duì)你工作學(xué)習(xí)有幫助,當(dāng)然你在寫寫幫文庫還可以找到更多《EXCEL表格中將數(shù)字金額轉(zhuǎn)換為英文》。

      第一篇:EXCEL表格中將數(shù)字金額轉(zhuǎn)換為英文

      Excel表格中如何將數(shù)字金額轉(zhuǎn)換為英文

      (如B1列寫162890元,自動(dòng)轉(zhuǎn)換為英文

      ONE HUNDRED SIXTY TWO THOUSAND EIGHT HUNDRED NINETY DOLLARS AND NO CENTS)

      1、新建Excel表格

      2、按住“Alt+F11”打開VBA編輯器

      3、在VBA編輯器中單擊菜單欄“插入”——模塊

      4、在打開的模塊中輸入如下代碼: Option Explicit Function 數(shù)字轉(zhuǎn)英文(ByValMyNumber)Dim Dollars, Cents, Temp Dim DecimalPlace, Count ReDimPlace(9)As String Place(2)= “ Thousand ” Place(3)= “ Million ” Place(4)= “ Billion ” Place(5)= “ Trillion ” MyNumber = Trim(Str(MyNumber))DecimalPlace = InStr(MyNumber, “.”)If DecimalPlace> 0 Then Cents = GetTens(Left(Mid(MyNumber, DecimalPlace + 1)& _

      “00”, 2))MyNumber = Trim(Left(MyNumber, DecimalPlace3)Else MyNumber = “" End If Count = Count + 1 Loop Select Case Dollars Case ”“ Dollars = ”No Dollars“ Case ”O(jiān)ne“ Dollars = ”O(jiān)ne Dollar“ Case Else Dollars = Dollars &” Dollars“ End Select Select Case Cents Case ”“ Cents = ” and No Cents“ Case ”O(jiān)ne“ Cents = ” and One Cent“ Case Else Cents = ” and “ & Cents & ” Cents“ End Select 數(shù)字轉(zhuǎn)英文 = Dollars & Cents End Function Function GetHundreds(ByValMyNumber)Dim Result As String If Val(MyNumber)= 0 Then Exit Function MyNumber = Right(”000“ &MyNumber, 3)If Mid(MyNumber, 1, 1)<> ”0“ Then Result = GetDigit(Mid(MyNumber, 1, 1))& ” Hundred “ End If 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 Function GetTens(TensText)Dim Result As String Result = ”“ If Val(Left(TensText, 1))= 1 Then 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 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))End If GetTens = Result End Function

      Function GetDigit(Digit)Select Case Val(Digit)Case 1: GetDigit = ”O(jiān)ne“ 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

      5/現(xiàn)在回到Excel表格中,單擊“B1”單元格,在菜單欄選擇“插入”——函數(shù)。6/在打開的“插入函數(shù)”對(duì)話框的“或選擇類別”中選擇“用戶定義”,然后選擇函數(shù)“數(shù)字轉(zhuǎn)英文”,單擊“確定”按鈕。

      7/在打開的“函數(shù)參數(shù)”對(duì)話框中輸入“A1”,單擊“確定”按鈕。8/ 然后用填充手柄向下填充公式,現(xiàn)在就可以看到轉(zhuǎn)換好的英文了。

      第二篇:阿拉伯?dāng)?shù)字金額轉(zhuǎn)換為英文會(huì)計(jì)金額

      怎樣用自定義函數(shù)將阿拉伯?dāng)?shù)字金額轉(zhuǎn)換為英文會(huì)計(jì)金額,如:123.45 變?yōu)椋篛ne Hundred Twenty Three Dollars and Forty Five Cents

      A:按Alt+F11,插入→模塊→在VBE窗口中輸入以下代碼:

      1.Function SpellNumber(ByValMyNumber)2.Dim Dollars, Cents, Temp 3.Dim DecimalPlace, Count 4.ReDim Place(9)As String 5.Application.Volatile True 6.Place(2)= “ Thousand ” 7.Place(3)= “ Million ” 8.Place(4)= “ Billion ” 9.Place(5)= “ Trillion ” ' String representation of amount 10.MyNumber = Trim(Str(MyNumber))' Position of decimal place 0 if none 11.DecimalPlace = InStr(MyNumber, “.”)12.'Convert cents and set MyNumber to dollar amount 13.If DecimalPlace> 0 Then 14.Cents = GetTens(Left(Mid(MyNumber, DecimalPlace + 1)& “00”, 2))15.MyNumber = Trim(Left(MyNumber, DecimalPlace3)23.Else 24.MyNumber = “" 25.End If 26.Count = Count + 1 27.Loop 28.Select Case Dollars 29.Case ”“ 30.Dollars = ”No Dollars“ 31.Case ”O(jiān)ne“ 32.Dollars = ”O(jiān)ne Dollar“ 33.Case Else 34.Dollars = Dollars & ” Dollars“ 35.End Select 36.Select Case Cents 37.Case ”“ 38.Cents = ” and No Cents“ 39.Case ”O(jiān)ne“ 40.Cents = ” and One Cent“ 41.Case Else 42.Cents = ” and “ & Cents & ” Cents“ 43.End Select 44.SpellNumber = Dollars & Cents 45.End Function 46.'******************************************* 47.' Converts a number from 100-999 into text * 48.'******************************************* 49.Function GetHundreds(ByValMyNumber)50.Dim Result As String 51.If Val(MyNumber)= 0 Then Exit Function 52.MyNumber = Right(”000“ &MyNumber, 3)'Convert the hundreds place 53.If Mid(MyNumber, 1, 1)<> ”0“ Then 54.Result = GetDigit(Mid(MyNumber, 1, 1))& ” Hundred “ 55.End If 56.'Convert the tens and ones place 57.If Mid(MyNumber, 2, 1)<> ”0“ Then 58.Result = Result &GetTens(Mid(MyNumber, 2))59.Else 60.Result = Result &GetDigit(Mid(MyNumber, 3))61.End If 62.GetHundreds = Result 63.End Function 64.'********************************************* 65.' Converts a number from 10 to 99 into text.* 66.'********************************************* 67.Function GetTens(TensText)68.Dim Result As String 69.Result = ”“ 'null out the temporary function value 70.If Val(Left(TensText, 1))= 1 Then ' If value between 10-19 71.Select Case Val(TensText)72.Case 10: Result = ”Ten“ 73.Case 11: Result = ”Eleven“ 74.Case 12: Result = ”Twelve“ 75.Case 13: Result = ”Thirteen“ 76.Case 14: Result = ”Fourteen“ 77.Case 15: Result = ”Fifteen“ 78.Case 16: Result = ”Sixteen“ 79.Case 17: Result = ”Seventeen“ 80.Case 18: Result = ”Eighteen“ 81.Case 19: Result = ”Nineteen“ 82.Case Else 83.End Select 84.Else ' If value between 20-99 85.Select Case Val(Left(TensText, 1))86.Case 2: Result = ”Twenty “ 87.Case 3: Result = ”Thirty “ 88.Case 4: Result = ”Forty “ 89.Case 5: Result = ”Fifty “ 90.Case 6: Result = ”Sixty “ 91.Case 7: Result = ”Seventy “ 92.Case 8: Result = ”Eighty “ 93.Case 9: Result = ”Ninety “ 94.Case Else 95.End Select 96.Result = Result &GetDigit _ 97.(Right(TensText, 1))'Retrieve ones place 98.End If 99.GetTens = Result 100.End Function 101.'******************************************* 102.' Converts a number from 1 to 9 into text.* 103.'******************************************* 104.Function GetDigit(Digit)105.Select Case Val(Digit)106.Case 1: GetDigit = ”O(jiān)ne“ 107.Case 2: GetDigit = ”Two“ 108.Case 3: GetDigit = ”Three“ 109.Case 4: GetDigit = ”Four“ 110.Case 5: GetDigit = ”Five“ 111.Case 6: GetDigit = ”Six“ 112.Case 7: GetDigit = ”Seven“ 113.Case 8: GetDigit = ”Eight“ 114.Case 9: GetDigit = ”Nine“ 115.Case Else: GetDigit = ”" 116.End Select 117.End Function 復(fù)制代碼

      然后在A1單元格輸入需要的數(shù)值,在其他單元格輸入=SpellNumber(A1)即可

      第三篇:將一個(gè)數(shù)字字符串轉(zhuǎn)換為整型數(shù)值

      將一個(gè)數(shù)字字符串轉(zhuǎn)換為整型數(shù)值

      C++編程:將一個(gè)數(shù)字字符串轉(zhuǎn)換為整型數(shù)

      #include

      #include

      void main()

      {

      int a;

      cout<<“請(qǐng)輸入一個(gè)數(shù)字字符串:”;

      cin>>a;

      if(47>a || a>57)

      cout<<“你輸入的不是數(shù)字字符串”<

      else

      {

      char n;

      n=int(a);

      cout<

      }

      }

      我寫了這段程序,但是同學(xué)說我錯(cuò)了,這是將ASCII碼轉(zhuǎn)為數(shù)字常量的,不符合題意,我想了很久都想不明白題目的意思,到底是什么意思呢??

      求高手指導(dǎo)!

      下載EXCEL表格中將數(shù)字金額轉(zhuǎn)換為英文word格式文檔
      下載EXCEL表格中將數(shù)字金額轉(zhuǎn)換為英文.doc
      將本文檔下載到自己電腦,方便修改和收藏,請(qǐng)勿使用迅雷等下載。
      點(diǎn)此處下載文檔

      文檔為doc格式


      聲明:本文內(nèi)容由互聯(lián)網(wǎng)用戶自發(fā)貢獻(xiàn)自行上傳,本網(wǎng)站不擁有所有權(quán),未作人工編輯處理,也不承擔(dān)相關(guān)法律責(zé)任。如果您發(fā)現(xiàn)有涉嫌版權(quán)的內(nèi)容,歡迎發(fā)送郵件至:645879355@qq.com 進(jìn)行舉報(bào),并提供相關(guān)證據(jù),工作人員會(huì)在5個(gè)工作日內(nèi)聯(lián)系你,一經(jīng)查實(shí),本站將立刻刪除涉嫌侵權(quán)內(nèi)容。

      相關(guān)范文推薦