3
Hello, my question is about a field validation for decymal value. If the value is less than 500,00 I show an error message, otherwise I pass to the second field, so the person type the value already adding the mask.
I’m using it this way:
function valid_simulation(form1) {
if(parseInt($("#selector").val()) < 500) {
alert("valor não é valido");
return false;
}
}
This way I can validate a value less than 500,00, but if it is more than 1,000,00 it shows the error message.
your field has mask? if yes, the problem may be the
.– rLinhares
Welcome to read this post https://answall.com/help/mcve
– user60252
Putting
parseFloatin place ofparseIntno longer solves?– Laércio Lopes
Laércio, won’t do it, thanks.
– josecarlos
rLinhares, yes has mask... if I take the point ai validates, but I need the point. I have to find a way to add the point and validate. Thanks.
– josecarlos