admin管理员组文章数量:1428551
Hi I am calling the following javascript when user clicks plete button which is to call validation on all of the validation groups which i have 3. but what is happening is that only the validation summary for the Photos one is being displayed when the others should also be showing. Can anyone help?
function EnsureValidation() {
Page_ClientValidate('PropertyInformation');
Page_ClientValidate('MarketCondition');
Page_ClientValidate('Photos');
}
Hi I am calling the following javascript when user clicks plete button which is to call validation on all of the validation groups which i have 3. but what is happening is that only the validation summary for the Photos one is being displayed when the others should also be showing. Can anyone help?
function EnsureValidation() {
Page_ClientValidate('PropertyInformation');
Page_ClientValidate('MarketCondition');
Page_ClientValidate('Photos');
}
Share
Improve this question
asked Feb 25, 2011 at 16:07
SomedeveloperSomedeveloper
8652 gold badges15 silver badges32 bronze badges
2 Answers
Reset to default 4See Page_ClientValidate() with multiple ValidationGroups - how to show multiple summaries simultaneously?
Edit
Can't you just call Page_ClientValidate()
(without any arguments) to validate all controls on the page?
I know this is an old post, The issue with using only Page_ClientValidate() is that, if you want to validate one group at a time, it won't work as it fires all the validation groups, you can do something like this,
function something(){
if(Page_ClientValidate('Save'))
{
//Your Code
}
else if (Page_ClientValidate('Group2'))
{
//your code
}
else
{
//your code
}
};
本文标签:
版权声明:本文标题:javascript - asp.net validation with validation group calling Page_ClientValidate not working as expected - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1745474262a2659887.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论