i have condition, where 2 questions are dependent on each other
when i select 1st Q as YES then next Q auto select to NO
if 1st select as NO then no action of 2nd Q
if second Q is YES then 1st to be auto select to NO
if second Q is NO then no action for 1st Q
Discussion posts and replies are publicly visible
a!localVariables( local!q1, local!q2, { a!columnsLayout( columns: { a!columnLayout( contents: { a!dropdownField( choiceLabels: {"Yes","No"}, choiceValues: {"Yes","No"}, label: "Question 1", labelPosition: "ABOVE", placeholder: "--- Select a Value ---", value: local!q1, saveInto: { local!q1, if( local!q1="Yes", a!save( local!q2, "No" ), {} ) }, searchDisplay: "AUTO", validations: {} ) } ), a!columnLayout( contents: { a!dropdownField( choiceLabels: {"Yes","No"}, choiceValues: {"Yes","No"}, label: "Question 1", labelPosition: "ABOVE", placeholder: "--- Select a Value ---", value: local!q2, saveInto: { local!q2, if( local!q2="Yes", a!save( local!q1, "No" ), {} ) }, searchDisplay: "AUTO", validations: {} ) } ), a!columnLayout( contents: {} ) } ) } )
try the above code and see if it works for you
You can easily do this manipulation in the component's saveInto. Check for the value and using an if() statement, simply do the required manipulation.
Any update?
HarleyOlsen What update are you looking for? This question has been answered.