Disable update button if user input contains errors

Description of the limitation and why it is relevant to address

If a user gives an invalid input value (e.g. the value should be >0, and the user enters -1000) the parameter is highlighted red, but the user is still able to click the “update” button to refresh the view.

Submitter proposed design (optional)

Even though nothing (should be) displayed in the view due to the invalid input value, I’d like to see a pop-up message if the user clicks the “update” button which tells the user that something is wrong.

Current workarounds

None

Thanks for this feedback, i’ve added it to our issue tracker

Hi Martijn,

This has been implemented with upgrade instruction U83 (SDK - Deprecations & Upgrades | VIKTOR Documentation), which has become default behavior in v14.

Please see this guide for more information: User input, fields and buttons - Input validation | VIKTOR Documentation.

1 Like