The problem is that in French language the decimal number is expected with "," instead of "."

Hi Team,

In Portal form i am facing below issue

 

The problem is that in French language the decimal number is expected with "," instead of "." .
So, my form is in English with a decimal field. My English users write 5.8 and it works while French users write 5.8 and it doesn't work while 5,8 works.
 can you please provide some solution on this issue

 

Thanks,

 

  Discussion posts and replies are publicly visible

Parents
  • Hello Ramesh, We can do this using substitute function on basis of user locale
    ex.
    a!textField(
    label: "Lorem Ipsum",
    labelPosition: "ABOVE",
    value:if(userlocale(loggedInUser())="fr_CA",if(rule!EBS_Utils_checkIsNull(ri!data),{},substitute(ri!data,".",",")),ri!data),
    saveInto: {
    a!save(ri!data,if(userlocale(loggedInUser())="fr_CA",todecimal(substitute(save!value,",",".")),save!value))
    },
    refreshAfter: "UNFOCUS",
    validations: {}
    )

    Here ri!data is the number(decimal) type field
Reply
  • Hello Ramesh, We can do this using substitute function on basis of user locale
    ex.
    a!textField(
    label: "Lorem Ipsum",
    labelPosition: "ABOVE",
    value:if(userlocale(loggedInUser())="fr_CA",if(rule!EBS_Utils_checkIsNull(ri!data),{},substitute(ri!data,".",",")),ri!data),
    saveInto: {
    a!save(ri!data,if(userlocale(loggedInUser())="fr_CA",todecimal(substitute(save!value,",",".")),save!value))
    },
    refreshAfter: "UNFOCUS",
    validations: {}
    )

    Here ri!data is the number(decimal) type field
Children