You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there a way to correct or rollback user's input if user's input is not valid according some business logic? for example, a percentage input have range [1-100], if current value is 80, user change to 102, our code change it to 100 or roll back to 80 and alert a invalid warning to user.
Now I am able to use onCellsChanged to add a new css to have different color if the value being changed. I can use this way to display red font when value is invalid if above quest can't be achieved.
Thanks,
Chen
The text was updated successfully, but these errors were encountered:
wangchen-ca
changed the title
validate user's input when using react-datasheet as data input form
[Question] validate user's input when using react-datasheet as data input form
Apr 22, 2021
There is no built in method to accomplish this out of the box, but you can use attributesRenderer to accomplish it similar to the method shown for adding hints.
Is there a way to correct or rollback user's input if user's input is not valid according some business logic? for example, a percentage input have range [1-100], if current value is 80, user change to 102, our code change it to 100 or roll back to 80 and alert a invalid warning to user.
Now I am able to use onCellsChanged to add a new css to have different color if the value being changed. I can use this way to display red font when value is invalid if above quest can't be achieved.
Thanks,
Chen
The text was updated successfully, but these errors were encountered: