Let say, I have two dropdown lists, both have required field validation controls and use Javascript to hide the second dropdown when choose the specific items from the first dropdown list. It works fine but the problem is when choose the specific items from the first dropdown it hides the second one but it still displays the required field validator.
So, the solution:
When we hide, we can disable the validator at the same time using ValidatorEnable().
function validate()
{
var myValidator = document.getElementById('myValidatorClientID');
ValidatorEnable(myValidator, false);
}
So, the solution:
When we hide, we can disable the validator at the same time using ValidatorEnable().
function validate()
{
var myValidator = document.getElementById('myValidatorClientID');
ValidatorEnable(myValidator, false);
}
To make enable replace that 'false' by 'true'.
Happy Programming !!!
No comments:
Post a Comment
Highly Appreciated your comments