NumberTextArabic

Adds Arabic unit to a number using proper Arabic grammar
Units can be customized in the call


Public

Tested

My Own Work
Function NumberTextArabic(Number As Integer, Optional String_Empty As String = "فارغ", _
Optional String1 = "قيد واحد", Optional String2 = "قيدان", Optional String3_10 = " قيود", _
Optional String11_ = " قيد") As String
NumberTextArabic = ""
If Number = 0 Then
NumberTextArabic = String_Empty
ElseIf Number = 1 Then
NumberTextArabic = String1
ElseIf Number = 2 Then
NumberTextArabic = String2
ElseIf Number > 2 And Number < 11 Then
NumberTextArabic = Number & String3_10
ElseIf Number > 10 Then
NumberTextArabic = Number & String11_
End If
End Function

Number, Optional String_Empty, Optional String1, Optional String2, Optional String3_10, Optional String11_

Views 4327 Downloads 1271

VBA Texts + Strings
ANmarAmdeen
813
Attachments
Revisions

v6.0