NbLettre.xla & KB3115262
Solved
Vince98800
Posted messages
3
Status
Membre
-
Vince98800 Posted messages 3 Status Membre -
Vince98800 Posted messages 3 Status Membre -
Hello,
I need NbLettre.xla (ConvNumberLetter) to edit my invoices in Excel.
Since KB3115262, the add-ins no longer work:
=ConvNumberLetter(*#) becomes
='C:\Users\...Roaming\Microsoft\AddIns\NbLettre.xla'!ConvNumberLetter(*#) (regardless of where the add-in is stored)
Is there a way to workaround this issue? Is there another way to write numbers in words?
I have tried a thousand manipulations before resorting to daily uninstalling of KB3115262. Of course, I leave a daily message to Microsoft while I'm at it. Are all add-ins affected? Will Microsoft eventually respond?
I need NbLettre.xla (ConvNumberLetter) to edit my invoices in Excel.
Since KB3115262, the add-ins no longer work:
=ConvNumberLetter(*#) becomes
='C:\Users\...Roaming\Microsoft\AddIns\NbLettre.xla'!ConvNumberLetter(*#) (regardless of where the add-in is stored)
Is there a way to workaround this issue? Is there another way to write numbers in words?
I have tried a thousand manipulations before resorting to daily uninstalling of KB3115262. Of course, I leave a daily message to Microsoft while I'm at it. Are all add-ins affected? Will Microsoft eventually respond?
5 réponses
Hello
I have an old function to test
=chiffrelettre(C2)
See you later
Maurice
I have an old function to test
=chiffrelettre(C2)
Function chiffrelettre(s) Dim a As Variant, gros As Variant a = Array("", "one", "two", "three", "four", "five", "six", "seven", _ "eight", "nine", "ten", "eleven", "twelve", "thirteen", "fourteen", "fifteen", "sixteen", _ "seventeen", "eighteen", "nineteen", "twenty", "twenty-one", "twenty-two", "twenty-three", "twenty-four", _ "twenty-five", "twenty-six", "twenty-seven", "twenty-eight", "twenty-nine", "thirty", "thirty-one", _ "thirty-two", "thirty-three", "thirty-four", "thirty-five", "thirty-six", "thirty-seven", _ "thirty-eight", "thirty-nine", "forty", "forty-one", "forty-two", "forty-three", _ "forty-four", "forty-five", "forty-six", "forty-seven", "forty-eight", _ "forty-nine", "fifty", "fifty-one", "fifty-two", "fifty-three", _ "fifty-four", "fifty-five", "fifty-six", "fifty-seven", "fifty-eight", _ "fifty-nine", "sixty", "sixty-one", "sixty-two", "sixty-three", _ "sixty-four", "sixty-five", "sixty-six", "sixty-seven", "sixty-eight", _ "sixty-nine", "seventy", "seventy-one", "seventy-two", "seventy-three", _ "seventy-four", "seventy-five", "seventy-six", "seventy-seven", _ "seventy-eight", "seventy-nine", "eighty", "eighty-one", _ "eighty-two", "eighty-three", "eighty-four", "eighty-five", _ "eighty-six", "eighty-seven", "eighty-eight", "eighty-nine", _ "eighty", "eighty-one", "eighty-two", "eighty-three", "eighty-four", _ "eighty-five", "eighty-six", "eighty-seven", "eighty-eight", "eighty-nine", _ "eighty", "eighty-one", "eighty-two", "eighty-three", "eighty-four", _ "eighty-five", "eighty-six", "eighty-seven", "eighty-eight", "eighty-nine", _ "eighty", "eighty-one", "eighty-two", "eighty-three", "eighty-four", _ "eighty-five", "eighty-six", "eighty-seven", "eighty-eight", "eighty-nine", _ "eighty", "eighty-one", "eighty-two", "eighty-three", "eighty-four", _ "eighty-five", "eighty-six", "eighty-seven", "eighty-eight", "eighty-nine", _ "eighty", "eighty-one", "eighty-two", "eighty-three", "eighty-four", _ "eighty-five", "eighty-six", "eighty-seven", "eighty-eight", "eighty-nine") gros = Array("", "billion", "billion", "million", "thousand", "euros", "billion", _ "billion", "million", "thousand", "euro") sp = Space(1) chaine = "00000000000000" centime = s * 100 - (Int(s) * 100) s = Str(Int(s)): Lg = Len(s) - 1: s = Right(s, Lg): Lg = Len(s) If Lg < 15 Then chaine = Mid(chaine, 1, (15 - Lg)) Else chaine = "" s = chaine + s 'billion to hundreds gp = 1 For k = 1 To 5 x = Mid(s, gp, 1): c = a(Val(x)) x = Mid(s, gp + 1, 2): d = a(Val(x)) If k = 5 Then If t2 <> "" And c & d = "" Then mydz = "Euros" & sp: GoTo Fin If t <> "" And c = "" And d = "one" Then mydz = "one euro" & sp: GoTo Fin If t <> "" And t2 = "" And c & d = "" Then mydz = "of euros" & sp: GoTo Fin If t & c & d = "" Then myct = "": mydz = "": GoTo Fin End If If c & d = "" Then GoTo Fin If d = "" And c <> "" And c <> "one" Then mydz = c & sp & "cents " & gros(k) & sp: GoTo Fin If d = "" And c = "one" Then mydz = "cent " & gros(k) & sp: GoTo Fin If d = "one" And c = "" Then myct = IIf(k = 4, gros(k) & sp, "one " & gros(k + 5) & sp): GoTo Fin If d <> "" And c = "one" Then mydz = "cent" & sp If d <> "" And c <> "" And c <> "one" Then mydz = c & sp & "cent" + sp myct = d & sp & gros(k) & sp Fin: t2 = mydz & myct t = t & mydz & myct mydz = "": myct = "" gp = gp + 3 Next d = a(centime) If t <> "" Then myct = IIf(centime = 1, " centime", " centimes") If t = "" Then myct = IIf(centime = 1, " centime of euro", "centimes of euro") If centime = 0 Then d = "": myct = "" chiffrelettre = t & d & myct End Function See you later
Maurice
I tested it; your code works.
Best regards