Ana içeriğe atla

Para birimini Excel'de sözcük metnine dönüştürmek nasıl?

İngilizceyi ikinci dilleri olarak kullanan ana dili İngilizce olmayanlar için, numara çok uzun olduğunda bazen para birimi numarasını doğrudan İngilizce kelimelere değiştirmek zordur. Bu makalede, Excel'de para birimini kolayca sözcük metnine nasıl dönüştürebileceğinizi öğreneceksiniz.

VBA kodu ile para birimini kelimelere dönüştürün
Kutools for Excel ile para birimini kelimelere dönüştürün


VBA kodu ile para birimini kelimelere dönüştürün

Aşağıdaki VBA kodu ile para birimi numarasını İngilizce kelimelere dönüştürebilirsiniz.

1. Basın Ara Toplam + F11 açmak için Uygulamalar için Microsoft Visual Basic iletişim kutusu.

2. içinde Uygulamalar için Microsoft Visual Basic iletişim kutusunu tıklayın Ekle > Modülü. Ardından aşağıdaki kodu kopyalayıp kod penceresine yapıştırın.

VBA kodu: Para birimi numarasını İngilizce kelimelere dönüştürün

Function NumberstoWords(ByVal pNumber)
Dim Dollars, Cents
arr = Array("", "", " Thousand ", " Million ", " Billion ", " Trillion ")
pNumber = Trim(Str(pNumber))
xDecimal = InStr(pNumber, ".")
If xDecimal > 0 Then
    Cents = GetTens(Left(Mid(pNumber, xDecimal + 1) & "00", 2))
    pNumber = Trim(Left(pNumber, xDecimal - 1))
End If
xIndex = 1
Do While pNumber <> ""
    xHundred = ""
    xValue = Right(pNumber, 3)
    If Val(xValue) <> 0 Then
        xValue = Right("000" & xValue, 3)
        If Mid(xValue, 1, 1) <> "0" Then
            xHundred = GetDigit(Mid(xValue, 1, 1)) & " Hundred "
        End If
        If Mid(xValue, 2, 1) <> "0" Then
            xHundred = xHundred & GetTens(Mid(xValue, 2))
        Else
            xHundred = xHundred & GetDigit(Mid(xValue, 3))
        End If
    End If
    If xHundred <> "" Then
        Dollars = xHundred & arr(xIndex) & Dollars
    End If
    If Len(pNumber) > 3 Then
        pNumber = Left(pNumber, Len(pNumber) - 3)
    Else
        pNumber = ""
    End If
    xIndex = xIndex + 1
Loop
Select Case Dollars
    Case ""
        Dollars = "No Dollars"
    Case "One"
        Dollars = "One Dollar"
    Case Else
        Dollars = Dollars & " Dollars"
End Select
Select Case Cents
    Case ""
        Cents = " and No Cents"
    Case "One"
        Cents = " and One Cent"
    Case Else
        Cents = " and " & Cents & " Cents"
End Select
NumberstoWords = Dollars & Cents
End Function
Function GetTens(pTens)
Dim Result As String
Result = ""
If Val(Left(pTens, 1)) = 1 Then
    Select Case Val(pTens)
        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(pTens, 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(pTens, 1))
End If
GetTens = Result
End Function
Function GetDigit(pDigit)
Select Case Val(pDigit)
    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

3. Basın Ara Toplam + Q kapatmak için aynı anda tuşları Uygulamalar için Microsoft Visual Basic iletişim kutusu.

4. Kelimelere dönüştürmek istediğiniz hücrenin bitişiğinde boş bir hücre (B1) seçin, formülü girin = NumberstoWords (A1)tuşuna basın ve ardından tuşuna basın. Keşfet tuşuna basın.

not: A1, hücrede para birimi numarasını içerir. İhtiyacınız olduğu gibi değiştirebilirsiniz.

5. B1 hücresini seçin, para birimi numaralarının tüm İngilizce kelimelerini almak için Dolgu Tutamaçını aşağı sürükleyin.


Kutools for Excel ile para birimini kelimelere dönüştürün

Bu uzun VBA kodu karmaşık görünüyor. Burada size bu sorunu kolayca çözmek için kullanışlı bir yardımcı program tanıtacağım. İle Sayılardan Kelimelere yarar Kutools for Excel, para birimini kelimelere dönüştürmek artık sorun olmayacak. Lütfen aşağıdaki işlemleri yapın.

Başvurmadan önce Kutools for ExcelLütfen önce indirin ve kurun.

1. Dönüştürmek istediğiniz para birimi numaralarını içeren hücreleri seçin.

2. tık Kutools > içerik > Sayılardan Kelimelere. Ekran görüntüsüne bakın:

3. içinde Para Birimi Kelimelerine Sayılar iletişim kutusunu seçin İngilizce seçeneğini tıklayın ve OK or Tamam düğmesine basın.

Şimdi seçilen para birimi numaraları hemen İngilizce kelimelere dönüştürülür.

  Bu yardımcı programın ücretsiz denemesine (30 günlük) sahip olmak istiyorsanız, indirmek için lütfen tıklayınızve ardından yukarıdaki adımlara göre işlemi uygulamaya gidin.

En İyi Ofis Üretkenlik Araçları

🤖 Kutools AI Yardımcısı: Aşağıdakilere dayalı olarak veri analizinde devrim yaratın: Akıllı Yürütme   |  Kodunu oluşturun  |  Özel Formüller Oluşturun  |  Verileri Analiz Edin ve Grafikler Oluşturun  |  Kutools İşlevlerini Çağır...
Popüler Özellikler: Yinelenenleri Bul, Vurgula veya Tanımla   |  Boş Satırları Sil   |  Veri Kaybı Olmadan Sütunları veya Hücreleri Birleştirin   |   Formülsüz Tur ...
Süper Arama: Çoklu Ölçütlü VLookup    Çoklu Değer VLookup  |   Birden Çok Sayfada VLookup   |   Bulanık Arama ....
Gelişmiş Açılır Liste: Hızla Açılır Liste Oluşturun   |  Bağımlı Açılır Liste   |  Çoklu Seçim Açılır Liste ....
Sütun Yöneticisi: Belirli Sayıda Sütun Ekleme  |  Sütunları Taşı  |  Gizli Sütunların Görünürlük Durumunu Değiştir  |  Aralıkları ve Sütunları Karşılaştırın ...
Öne Çıkan Özellikler: Izgara Odağı   |  Tasarım görünümü   |   Büyük Formül Çubuğu    Çalışma Kitabı ve Sayfa Yöneticisi   |  Kaynak Kütüphanesi (Otomatik metin)   |  Tarih Seçici   |  Çalışma Sayfalarını Birleştirin   |  Hücreleri Şifrele/Şifresini Çöz    E-postaları Listeye Göre Gönder   |  Süper Filtre   |   Özel Filtre (kalın/italik/üstü çizili filtre...) ...
En İyi 15 Araç Seti12 Metin Tools (Metin ekle, Karakterleri Kaldır, ...)   |   50+ Grafik Türleri (Gantt şeması, ...)   |   40+ Pratik Formüller (Yaşı doğum gününe göre hesapla, ...)   |   19 sokma Tools (QR Kodunu Girin, Yoldan Resim Ekle, ...)   |   12 Dönüştürme Tools (Sayılardan Kelimelere, Para Birimi Dönüştürme, ...)   |   7 Birleştir ve Böl Tools (Gelişmiş Kombine Satırları, Bölünmüş hücreler, ...)   |   ... ve dahası

Kutools for Excel ile Excel Becerilerinizi Güçlendirin ve Daha Önce Hiç Olmadığı Gibi Verimliliği Deneyimleyin. Kutools for Excel, Üretkenliği Artırmak ve Zamandan Tasarruf Etmek için 300'den Fazla Gelişmiş Özellik Sunar.  En Çok İhtiyacınız Olan Özelliği Almak İçin Buraya Tıklayın...

Açıklama


Office Tab, Office'e Sekmeli Arayüz Getirir ve İşinizi Çok Daha Kolay Hale Getirir

  • Word, Excel, PowerPoint'te sekmeli düzenlemeyi ve okumayı etkinleştirin, Publisher, Access, Visio ve Project.
  • Yeni pencereler yerine aynı pencerenin yeni sekmelerinde birden çok belge açın ve oluşturun.
  • Üretkenliğinizi% 50 artırır ve her gün sizin için yüzlerce fare tıklamasını azaltır!
Comments (19)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
Write the currency AED 3862.54 in words
This comment was minimized by the moderator on the site
can convert it to malaysian ringgit ?
This comment was minimized by the moderator on the site
Hi Warsha,

This type of conversion is not supported yet. Sorry for the inconvenience.
This comment was minimized by the moderator on the site
Hello help, I love your formula but I would like to update the formula so that it stays like the example in capital letters. Thanks a lot.
Example:
USD 121,500.56 = One Hundred Twenty One Thousand Five Hundred Dollars and Fifty Six Cents
***ONE HUNDRED TWENTY ONE THOUSAND FIVE HUNDRED AND 56/100 US DOLLARS

USD 121,500.00 = One Hundred Twenty One Thousand Five Hundred Dollars and No Cents
***ONE HUNDRED TWENTY ONE THOUSAND FIVE HUNDRED AND 00/100 US DOLLARS
This comment was minimized by the moderator on the site
Hi Angel,
The following VBA code can do you a favor. After adding the code to the Module (Code) window. Don't forget to apply this formula =NumberstoWords(cell) to get the result.
Function NumberstoWords(ByVal pNumber)
'Updated by Extendoffice 20221123
Application.Volatile

Dim Dollars, Cents
arr = Array("", "", " Thousand ", " Million ", " Billion ", " Trillion ")
pNumber = Trim(Str(pNumber))
xDecimal = InStr(pNumber, ".")

If xDecimal > 0 Then
    Cents = Left(Mid(pNumber, xDecimal + 1) & "00", 2)
    Cents = "AND " & Cents & "/100 US DOLLARS"
    pNumber = Trim(Left(pNumber, xDecimal - 1))
Else
    Cents = "AND " & "00/100 US DOLLARS"
End If


xIndex = 1
Do While pNumber <> ""
    xHundred = ""
    xValue = Right(pNumber, 3)
    If Val(xValue) <> 0 Then
        xValue = Right("000" & xValue, 3)
        If Mid(xValue, 1, 1) <> "0" Then
            xHundred = GetDigit(Mid(xValue, 1, 1)) & " Hundred "
        End If
        If Mid(xValue, 2, 1) <> "0" Then
            xHundred = xHundred & GetTens(Mid(xValue, 2))
        Else
            xHundred = xHundred & GetDigit(Mid(xValue, 3))
        End If
    End If
    If xHundred <> "" Then
        Dollars = xHundred & arr(xIndex) & Dollars
    End If
    If Len(pNumber) > 3 Then
        pNumber = Left(pNumber, Len(pNumber) - 3)
    Else
        pNumber = ""
    End If
    xIndex = xIndex + 1
Loop
Select Case Dollars
    Case ""
        Dollars = "No Dollars"
    Case "One"
        Dollars = "One Dollar"
    Case Else
        Dollars = Dollars
End Select
NumberstoWords = UCase(Dollars & Cents)
End Function
Function GetTens(pTens)
Dim Result As String
Result = ""
If Val(Left(pTens, 1)) = 1 Then
    Select Case Val(pTens)
        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(pTens, 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(pTens, 1))
End If
GetTens = Result
End Function
Function GetDigit(pDigit)
Select Case Val(pDigit)
    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
This comment was minimized by the moderator on the site
Can you update the code to use Dinar and Fils .. Fils decimal is 3 .. means it has hundreds, tens and ones..
Thank you ..
This comment was minimized by the moderator on the site
Hi Naseem,
Perhaps the VBA code on the following page can help.
Convert numbers to words using Dinar and Fils.
This comment was minimized by the moderator on the site
Thank you so much ..
Can you update the to write the fills in number not word.
125.100 --> One Hundred Twenty Five Kuwaiti Dinar and 100 Fils Only

Thanks
This comment was minimized by the moderator on the site
Want a solution that doesn't require VBA?
Check it out here
See result in screenshot
This comment was minimized by the moderator on the site
This comment was minimized by the moderator on the site
I love your macro. Found one thing that doesn't quite work well. That's when there is a fractional. For instance if a field comes up as .835 excel rounds it up but the value is typed as "eighty three cents" while excel shows .84.
Work around for this?
This comment was minimized by the moderator on the site
Hi,
Sorry for the inconvenience. We have updated the code, please give it a try.

Function NumberstoWords(ByVal pNumber)
'Updated by Extendoffice 20220428
Dim Dollars, Cents
arr = Array("", "", " Thousand ", " Million ", " Billion ", " Trillion ")
pNumber = Trim(Str(pNumber))
pNumber = Round(pNumber, 2)
xDecimal = InStr(pNumber, ".")
If xDecimal > 0 Then
    Cents = GetTens(Left(Mid(pNumber, xDecimal + 1) & "00", 2))
    pNumber = Trim(Left(pNumber, xDecimal - 1))
End If
xIndex = 1
Do While pNumber <> ""
    xHundred = ""
    xValue = Right(pNumber, 3)
    If Val(xValue) <> 0 Then
        xValue = Right("000" & xValue, 3)
        If Mid(xValue, 1, 1) <> "0" Then
            xHundred = GetDigit(Mid(xValue, 1, 1)) & " Hundred "
        End If
        If Mid(xValue, 2, 1) <> "0" Then
            xHundred = xHundred & GetTens(Mid(xValue, 2))
        Else
            xHundred = xHundred & GetDigit(Mid(xValue, 3))
        End If
    End If
    If xHundred <> "" Then
        Dollars = xHundred & arr(xIndex) & Dollars
    End If
    If Len(pNumber) > 3 Then
        pNumber = Left(pNumber, Len(pNumber) - 3)
    Else
        pNumber = ""
    End If
    xIndex = xIndex + 1
Loop
Select Case Dollars
    Case ""
        Dollars = "No Dollars"
    Case "One"
        Dollars = "One Dollar"
    Case Else
        Dollars = Dollars & " Dollars"
End Select
Select Case Cents
    Case ""
        Cents = " and No Cents"
    Case "One"
        Cents = " and One Cent"
    Case Else
        Cents = " and " & Cents & " Cents"
End Select
NumberstoWords = Dollars & Cents
End Function
Function GetTens(pTens)
Dim Result As String
Result = ""
If Val(Left(pTens, 1)) = 1 Then
    Select Case Val(pTens)
        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(pTens, 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(pTens, 1))
End If
GetTens = Result
End Function
Function GetDigit(pDigit)
Select Case Val(pDigit)
    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
This comment was minimized by the moderator on the site
This macro here helped me a lot, thank you so much for that. Our currency here in Kuwait has 3 digits after the decimal, could you help me with this?
This comment was minimized by the moderator on the site
If 45.67 is written as forty-five dollars, sixty-seven cents, how's 45.678 written? Is it forty-five dollars, six hundred and seventy-eight cents?
This comment was minimized by the moderator on the site
can't be changed the currency
This comment was minimized by the moderator on the site
Review the article Million billion trillion conversion beginner guideline to learn and understand about number system and number conversion.
This comment was minimized by the moderator on the site
currency is always in Dollar and cents, How can we change this to other currency?
This comment was minimized by the moderator on the site
You can change the code to your currency instead of "dollers"
This comment was minimized by the moderator on the site
Mr. Shaji can you guide with the steps Please
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations