Is it possible to apply client side validation in radio button?

Is it possible to apply client side validation in radio button?

  

How to create client-side validation in radio button control.

Please help...

AV

Thanks

Hi Amit Verma,

Yes is possible to validate client side, however you need to do your code for this (something like):

        function ValidRadioButtons() {
            "foreach radio button"
            "if no selected return false"
        }

Then in extended properties of radio button, set onchange to call your javascript method:

Regards,

Marco Arede wrote:

Hi Amit Verma,

Yes is possible to validate client side, however you need to do your code for this (something like):

        function ValidRadioButtons() {
            "foreach radio button"
            "if no selected return false"
        }

Then in extended properties of radio button, set onchange to call your javascript method:

Regards,

Hello Marco Arede,

Thanks for reply.

Can i apply CSS to indicate this is mandatory field same like input textbox. (e.g red or any other indicator)

Thanks,

AV



You can set Style Classes for a radio button, but to explain is mandatory, I'd just place a star nearby (in text maybe).

Marco Arede wrote:

You can set Style Classes for a radio button, but to explain is mandatory, I'd just place a star nearby (in text maybe).

Hi Macro,

Without javascript any other way....

Thanks,

AV



Amit Verma, OutSystems does not have an incorporated client validation for radio buttons.

Hello Amit,


Why you need that the validation must be done in client side?

Regards