Hi,
I need to validate that one or more checkboxes have been checked in a group. I read some other relative threads about that in this forum but I can't find my way with the responses. I was thinking it was something close to the way we do with radio-buttons, so I just replaced type=radio with type=checkbox in the following dojo example: http://dojo.telerik.com/uHEto
It seems that kendo.validate() does not pass on input type=checkbox (except when already checked !) and it appears to be an issue to me.
Note that I want to make this checkboxes' validation with kendo validator, not on an event like onsubmit for instance.
thank you for your help
5 Answers, 1 is accepted
The validation will not pass because you are using the required attribute which will validate the input on its own. You should use another attribute to determine if the checkbox should be validated in order to avoid triggering the default required validation.
Regards,
Daniel
Telerik
Hi Daniel,
Thank you for your answer, seems a bit more clear to me, but can you explain why it's working as is with radio buttons ?
Regards,
Laurent
It will work as it is for radio buttons if the radio buttons value is set. The default required validation has support for validating checkboxes based on their checked state. Radio buttons will be validated as normal inputs based on the value.
Regards,
Daniel
Telerik
Hi,
use checkbox in mvc but i need send controller side, somebody knows properties used in helper the checkbox().
Hello Yazmin,
I am not exactly sure what you are after. Can you elaborate more on the case and describe better what are the requirements and what you are trying to achieve?
Also, as I can see your question is about checkbox and the thread here is about validation. Therefore, it is suggested to open a new thread regaridng your question with more details, code samples and if it is related to Kendo Validator to describe better how it incorporated with the checkbox you are using.
Regards,
Ianko
Telerik by Progress