Hi,
at the aspx page disable the validator for the surname with the enable = false.
and then in the code behind page attach the attributes for the button click to call following client side function with passing the Surname validator 's client id as the parameter
function test(val)
{
var myVal = document.getElementById(val);
var Nametextbox = document.getElementById('NameTextBoxID');
if(Nametextbox.value != ' ')
{
ValidatorEnable(myVal, true);
}
if(Page_ClientValidate() == true)
{
return true;
}
return false;
}
The idea is to enable the surname validator only when the use has entered the value in the Name field , this way at a time only one validator will fire.