validation code
function YourButtonClickEvent() { var validation = Page_ClientValidate(); if (!validation) { for (var i = 0; i < Page_Validators.length; i++) { if (!Page_Validators[i].isvalid) { $("#" + Page_Validators[i].controltovalidate).css("border-color", "red"); } } } return val; }