如何通过单个按钮验证GridView和外部单选按钮的检查 [英] How to validate check in gridview and radio button outside with single button

查看:78
本文介绍了如何通过单个按钮验证GridView和外部单选按钮的检查的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,
我有带有复选框和外部单选按钮列表的网格视图,如何在单击按钮的同时在网格视图和单选按钮列表中选中复选框,如何在单个按钮上设置所需的字段验证器
您可以指导我还是发送任何代码片段

Hello,
I have grid view with check boxes and outside radiobutton list how can i set requried feild validator at single button while click on button at we have to check box in grid view and radiobuttonlist
can u guide me or send any snippets

推荐答案

hi 如果您想拥有这种功能,请右键单击requiredField和goto属性,并为ValidationGroup分配一些值,例如 1 现在将 1 分配给所有其他requiredFeild验证如要单击的按钮一样.
通过使用此选项,将仅触发那些ValidationGroup与按钮的Validation Group相匹配的验证.
我希望这能解决您的问题:)
hi if u want to have this kind of functionality right click on the requiredField and goto properties and assign some value to ValidationGroup lets say 1 Now assign 1 to all other requiredFeild validations as well as on button which you want to be fired when it is clicked.
by using this only those validations will be fired whose ValidationGroup will matches with the button''s Validation Group.
I hope this will solve your problem :)


先生;
据我了解,当在单选列表中选择某个值时,必须确保至少选中一个复选框.
因此,您需要添加具有
客户端验证功能的自定义验证器
Sir;
What I understood that you have to make sure that at least one check box is checked when a certain value is selected in the radio list.
so, you need to add a custom validator with client validation function of
function ValidateItemCheck(sender, e){
    var selectedoption =


(" ); 如果(selectedoption.val()== ' somevalue' ){ var gridview =
("input[id^='<%= radiolist.ClientID %>_']:checked"); if (selectedoption.val() == 'somevalue') { var gridview =


这篇关于如何通过单个按钮验证GridView和外部单选按钮的检查的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆