أنشئ حسابًا أو سجّل الدخول للانضمام إلى مجتمعك المهني.
good question.
unfortunately, there is no build-in function in Excel to have this behavior automatically.
you can check on this
How to convert a numeric value into English words in Excel
hope this help.
Regards
There is a spell number macro has to be download, it can do the Job perfectly.
There was a function for it in older Excel called "SpellNumber" i think, but not sure about it.
In Excel you have to use Macro.
I just tried it in my Excel for Mac and it works. Don't forget to select the cells whose contents you want to convert and then use the macro:
Sub NumberToWords() Dim rngSrc As Range Dim lMax As Long Dim lCtr As Long Dim bNCFlag As Boolean Dim sTitle As String, sMsg As String Dim vCVal As Variant Dim lNumber As Long, sWords As String Set rngSrc = ActiveSheet.Range(ActiveWindow.Selection.Address) lMax = rngSrc.Cells.Count bNCFlag = False For lCtr =1 To lMax vCVal = rngSrc.Cells(lCtr).Value sWords = "" If IsNumeric(vCVal) Then If vCVal <> CLng(vCVal) Then bNCFlag = True Else lNumber = CLng(vCVal) Select Case lNumber Case0 sWords = "Zero" Case1 To sWords = SetThousands(lNumber) Case Else bNCFlag = True End Select End If Else bNCFlag = True End If If sWords > "" Then rngSrc.Cells(lCtr) = sWords End If Next lCtr If bNCFlag Then sTitle = "lNumberToWords Macro" sMsg = "Not all cells converted. May not be whole number or may be too large." MsgBox sMsg, vbExclamation, sTitle End If End Sub Private Function SetOnes(ByVal lNumber As Integer) As String Dim OnesArray(9) As String OnesArray(1) = "One" OnesArray(2) = "Two" OnesArray(3) = "Three" OnesArray(4) = "Four" OnesArray(5) = "Five" OnesArray(6) = "Six" OnesArray(7) = "Seven" OnesArray(8) = "Eight" OnesArray(9) = "Nine" SetOnes = OnesArray(lNumber) End Function Private Function SetTens(ByVal lNumber As Integer) As String Dim TensArray(9) As String TensArray(1) = "Ten" TensArray(2) = "Twenty" TensArray(3) = "Thirty" TensArray(4) = "Fourty" TensArray(5) = "Fifty" TensArray(6) = "Sixty" TensArray(7) = "Seventy" TensArray(8) = "Eighty" TensArray(9) = "Ninety" Dim TeensArray(9) As String TeensArray(1) = "Eleven" TeensArray(2) = "Twelve" TeensArray(3) = "Thirteen" TeensArray(4) = "Fourteen" TeensArray(5) = "Fifteen" TeensArray(6) = "Sixteen" TeensArray(7) = "Seventeen" TeensArray(8) = "Eighteen" TeensArray(9) = "Nineteen" Dim iTemp1 As Integer Dim iTemp2 As Integer Dim sTemp As String iTemp1 = Int(lNumber /) iTemp2 = lNumber Mod sTemp = TensArray(iTemp1) If (iTemp1 =1 And iTemp2 >0) Then sTemp = TeensArray(iTemp2) Else If (iTemp1 >1 And iTemp2 >0) Then sTemp = sTemp + " " + SetOnes(iTemp2) End If End If SetTens = sTemp End Function Private Function SetHundreds(ByVal lNumber As Integer) As String Dim iTemp1 As Integer Dim iTemp2 As Integer Dim sTemp As String iTemp1 = Int(lNumber /) iTemp2 = lNumber Mod If iTemp1 >0 Then sTemp = SetOnes(iTemp1) + " Hundred" If iTemp2 >0 Then If sTemp > "" Then sTemp = sTemp + " " If iTemp2 < Then sTemp = sTemp + SetOnes(iTemp2) If iTemp2 >9 Then sTemp = sTemp + SetTens(iTemp2) End If SetHundreds = sTemp End Function Private Function SetThousands(ByVal lNumber As Long) As String Dim iTemp1 As Integer Dim iTemp2 As Integer Dim sTemp As String iTemp1 = Int(lNumber /) iTemp2 = lNumber Mod If iTemp1 >0 Then sTemp = SetHundreds(iTemp1) + " Thousand" If iTemp2 >0 Then If sTemp > "" Then sTemp = sTemp + " " sTemp = sTemp + SetHundreds(iTemp2) End If SetThousands = sTemp End Function
Or you can copy it from here as well.. probably better : Click here
Macro has to be download first and many spell number are there. Need to practice, so the it can run properly.