The "value" field in the radiobuttons is disabled and can not be assigned a value, so it is not possible that the user can assign a custom value when the radiobutton is selected, as you can do with the checkboxes for example.
Currently when you get the value of a group of radiobuttons it simply adds "0", "1", "2", etc. to the name of the radiobutton, so it is very complicated to know which radiobutton has been selected and does not allow the user to assign a custom value.
Add three radiobuttons with the same name "radios", as in the following image.
If you click on the button "Get value radiobuttons", the console displays the value obtained: "radios0", "radios1" or "radios2".
Is there the possibility of being able to assign a custom value to the "value" field of the radiobutton and when you get the value of that group of radiobuttons get the custom value of the selected radiobutton? it would be very useful.
Thank you very much!
Currently, there is no support for assigning the values for the radio button. We have logged this as a feature request as "Enable the value property on checkbox and radio button". We will implement this feature in our upcoming 2023 volume 1 release and let you know once this feature is implemented. You can track the status using the below feedback link.
When will this bug be fixed? I would need to be able to create radiobuttons where I can assign a value to each radiobutton and then get the value of the selected option.
We apologize that the feature is not implemented in our
Volume 1, 2023 Main release. Due to various priorities in our roadmap and other
commitments we couldn’t implement as informed. However, we will implement this
feature in our upcoming Volume 1, 2023 SP release expected to be rolled out in
the mid of May 2023.
Appreciate your patience.
Ok, thank you!