Issue
I need help enabling only one widget at a time - either an input or a select widget. Whenever I write a number in the input widget, the select widget should be disabled and vice versa. I tried using {{input.isDisabled}} and {{sel.isDisabled}}, but it's not working correctly. How can I properly disable these widgets?
Resolution
To ensure that only one widget—such as an Input or Select widget—is active at a time, you can use their respective Disabled properties. By evaluating whether one widget contains a value, you can conditionally disable the other based on its state.
For instance, if a text is entered in the Input widget, you can disable the Select widget by setting its Disabled property to an expression like {{!!Input1.text}}
. This converts the input value to a boolean, disabling the Select widget when the Input has content. Conversely, if an option is selected in the Select widget, you can disable the Input widget using {{!!Select1.selectedOptionValue}}
.
These boolean expressions allow you to dynamically control which widget is enabled, based on user interaction with either widget.