Is there any solution in Integerfiel to generate an Amount Format? but in textField my logic is working but my validations is not working. My validation is only numbers can accept in textField.
Discussion posts and replies are publicly visible
For simple number validation within text field you can use cleanwith() function. Generally regex is used for more complex validations that involve pattern matching like email formats, etc.
a!textField( label: "Formatted Number", value: if( or(isnull(ri!formattedNumber), ri!formattedNumber <> cleanwith(ri!formattedNumber, "1234567890.,")), ri!formattedNumber, text(ri!formattedNumber, "##,###.##") ), saveInto: ri!formattedNumber, validations: { if( ri!formattedNumber <> cleanwith(ri!formattedNumber, "1234567890.,"), "Please input numbers only", {} ) } )
I also tried this but I have problem says "Interface Definition: Expression evaluation error at function 'cleanwith' [line 112]: A null parameter has been passed as parameter 1."