I have a localization problem. In Brazil, we use a comma as a decimal separator instead of a period. For instance:
500,00 120,21 0,0001
I found a solution to this problem based on this answer: MVC 3 jQuery Check / Globalize Number / Decimal Field
But here in Brazil, we also use ".". in numbers, for example:
100.000.000,00 11.125,23
One more thing:
10.000 <> 10,000
The first is ten thousand, and the second is ten.
Using the globalization plugin, when the user enters β.β, It shows a validation error. I tried using DisplayFormat data annotation, but it did not work as expected ... To "solve" these problems, I use javascript to install and uninstall manually. from the numbers on the field, but this is very problematic when we need to change something (and I'm sure this is one of the worst approaches that I could use ...). Do you guys know how to act in this case?
One more question: can I create a model binding (or modify an existing one) to accept this number format?
source share