Skip to main content

Notifications

Microsoft Dynamics AX forum
Suggested answer

SSRS > How to display numbers in an Arabic format?

Posted on by 855

Hello awesome community!

I am trying to display numbers of the variables in my dataset in an Arabic format ( ١ ٢ ٣ ) .

I tried setting the property of the text box "Numeral Language" to "ar-SA" but nothing has changed.

What should I do to make them show in an Arabic format?

Any adivce would be appreciated 

Thanks in advance!

  • Momochi Profile Picture
    Momochi 855 on at
    RE: SSRS > How to display numbers in an Arabic format?

    Hello Blue Wang,

    I already tried changing the NumeralVariant to 3 but still nothing has changed.

    I did try again today after I read your reply and cleared the chaches and I did reset the services of Ax object and SQL reporting services but nothing has changed unfortunately.... I tried it on a simple text box with a value of "123"

    Thanks.

  • Blue Wang Profile Picture
    Blue Wang on at
    RE: SSRS > How to display numbers in an Arabic format?

    Hi Momochi,

    I've looked at your problem description again.

    You only mentioned that you changed the NumeralLanguage property, and whether you changed the NumeralVariant property.

    80.PNG
    The report needs to be redeployed after the change, otherwise it will not work.

  • Blue Wang Profile Picture
    Blue Wang on at
    RE: SSRS > How to display numbers in an Arabic format?

    Hi Momochi,

    The format you use is C# code,So you can't put the code in directly.

    If you want to use it in VB, you should use:

             <DataMethod(), PermissionSet(SecurityAction.Assert, Name:="FullTrust")>

             Public Shared Function GetCustomerData() As System.String

             End Function

    [View:https://docs.microsoft.com/en-us/dynamicsax-2012/appuser-itpro/how-to-define-a-data-method-in-csharp:750:50]

    [View:https://docs.microsoft.com/en-us/dynamicsax-2012/appuser-itpro/how-to-define-a-data-method-in-visual-basic:750:50]

  • Momochi Profile Picture
    Momochi 855 on at
    RE: SSRS > How to display numbers in an Arabic format?

    Hello Blue Wang,

    I followed the video tutorials and created a datamethod and used the code you typed previously.

    I used it on a simple text box that has a value of "123" , Here is the expression: DataMethod1("123") 

    But unfortunately when I run the report it displays as "???".

    It seems that the code does not recognize the Arabic numbers.

    Here is the method code:

    [DataMethod(), PermissionSet(SecurityAction.Assert, Name = "FullTrust")]
    public static string DataMethod1(string result)
    {
    result = result.Replace("1", "۱");

    result = result.Replace("2", "۲");

    result = result.Replace("3", "۳");

    result = result.Replace("4", "٤");

    result = result.Replace("5", "۵");

    result = result.Replace("6", "٦");

    result = result.Replace("7", "۷");

    result = result.Replace("8", "۸");

    result = result.Replace("9", "۹");

    result = result.Replace("0", "۰");
    return result;
    }

  • Blue Wang Profile Picture
    Blue Wang on at
    RE: SSRS > How to display numbers in an Arabic format?

    Hi Momochi,

    I overlooked that this is the AX Forum.

    You can use Data Methods.

    Please refer this: [View:https://community.dynamics.com/ax/b/axcasperkamals/posts/data-methods-in-ax-reports-and-ssrs-reports:750:50]

  • Momochi Profile Picture
    Momochi 855 on at
    RE: SSRS > How to display numbers in an Arabic format?

    Oh, unfortunately...

    Anyway thank you for your time and help! :)

  • Blue Wang Profile Picture
    Blue Wang on at
    RE: SSRS > How to display numbers in an Arabic format?

    Hi Momochi,

    Sorry,My fault.

    AX SSRS does not support VB code.

  • Momochi Profile Picture
    Momochi 855 on at
    RE: SSRS > How to display numbers in an Arabic format?

    Sure

    Here is the expression:

    Capture-22.PNG

    Here is the error output:

    774000.Capture.PNG

    Maybe custom code is not supported with AX?

  • Blue Wang Profile Picture
    Blue Wang on at
    RE: SSRS > How to display numbers in an Arabic format?

    Hi Momochi,

    Code.Arabic(Fields!SalesOrderInvoiceCount.Value)

    This "Arabic" is the function method name.

    Public Shared Function Arabic(input As String) As String.

    Is it convenient to upload screenshots?

  • Momochi Profile Picture
    Momochi 855 on at
    RE: SSRS > How to display numbers in an Arabic format?

    Thank you Blue Wang for the detailed answer!

    I followed your steps but when I deployed the report it gave me an error saying "Arabic is an invalid. InvalidIdentifier".

    I'm not sure why it's not working

Helpful resources

Quick Links

Dynamics 365 Community Update – Sep 9th

Welcome to the next edition of the Community Platform Update. This is a weekly…

Announcing Our 2024 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,186 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 227,996 Super User 2024 Season 2

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans