I have a text input field in my canvas form formatted as number. As the default value I'm using a variable named varPayInput. For the OnChange event of that field I'm using the following formula:
UpdateContext({varPayInput: Text(Value(DataCardValue7.Text), "$#,##0.00")})
This formats the field to currency after someone inputs an amount, and it works beautifully, however, when the record gets submitted the amount previously input doesn't go away. I'm assuming it has to do with the variable, but I'm not sure how to remove it. I've tried various how to's from Google to no avail.
HI @ShawnPelletier ,
In the OnSuccess property of the form you need to set the variable to blank:
UpdateContext({varPayInput:Blank()})
By using the OnSuccess property you are certain the form is successfully submitted before resetting the variable.