Radio buttons and Text

Radio buttons and Text

  
Hi!
When you have serveral radio buttons, let's say 5 radio buttons with options, and aquiring the respective label, and you have a 6th radio button to choose Other ad binding it with an input field for the user to write another option that there isn't available in the previous radio buttons options, how he assume teh value writeen by teh end user on te save action?
The Input bind is type text. 
On my save action, all values apear well, choosing all other radio buttons, but null value when select teh input user. I've attached an image. 

Best regards

Hi Andrew,

That's happening because you're assigning as a value to the RadioButton variable the variable from the Input. So when you type something you'd need another roundtrip to the server in order for the variable to have the value and would be correctly assigned.

From my view you could:

1) On the OnChange of the TextInputField you could refresh the radio (sing a screen action and AjaxRefresh) and that would perhaps assign the correct value to the button. Howheve if you click fast enough in the submit button you might get into some inconsistency.

2) You could assign some known value when you select the "Outro" checkbox and then server side if the variable from the edit record has that know value you could assign to the variable the value from the variable bound to the input field.

Personally I'd choose the 2nd option.

Hope this helps
Guilherme