So i have a which i'm catching the event of it with the ClientValidationFunction. 

The problem i'm having is, i'm doing some process with it and outcome of this process should determine whether the args.IsValid should be true or false. But the results i'm catching are in callback where i can't seem to find a way to acces args.

I've defined a var Args globaly and tried to get the value from there; couldn't get it.

I've tried to send it via userContext; no use (think it only accepts string).

I've tried to get the validator by document.getElementById, and i couldn't find the args property. This one is the one i'm most logical to me but i can't seem to find it.

The javascript code i wrote is as this;

```
function ValidateUserMail(oSrc, args) {
    var myField = document.getElementById('<%=RegisterUserWizardStep.ContentTemplateContainer.FindControl("Email").ClientID %>');
    PageMethods.IsMailAvailable(myField.value, OnSucceeded); 
}

//i need to edit args value from this function below.
function OnSucceeded(result, userContext, methodName) {
    if (methodName == "IsMailAvailable")
        if (!result) {
            var myValidator = document.getElementById('<%=RegisterUserWizardStep.ContentTemplateContainer.FindControl("UniqueEmailRequired").ClientID %>');
            myValidator.args = false; //doesn't work any ideas about the working property?
        }
}

```

and the code i wrote in aspx for validator is as this;

```
  <asp:RequiredFieldValidator ID="EmailRequired" runat="server" ControlToValidate="Email" 
  CssClass="failureNotification" ErrorMessage="E-mail is required." ToolTip="E-mail is required." 
  ValidationGroup="RegisterUserValidationGroup">*</asp:RequiredFieldValidator>

  <asp:CustomValidator ID="UniqueEmailRequired" runat="server" ControlToValidate="Email"
  CssClass="failureNotification" ErrorMessage="Unique E-mail is required." ToolTip="Unique E-mail is required."
  ValidationGroup="RegisterUserValidationGroup" ClientValidationFunction="ValidateUserMail">*</asp:CustomValidator>

```

Thanks a lot!

---

Update; rendered html for uniqueEmailValidator Javascript in browser;

```
    var MainContent_RegisterUser_CreateUserStepContainer_UniqueEmailRequired = document.all ? document.all["MainContent_RegisterUser_CreateUserStepContainer_UniqueEmailRequired"] : document.getElementById("MainContent_RegisterUser_CreateUserStepContainer_UniqueEmailRequired");
    MainContent_RegisterUser_CreateUserStepContainer_UniqueEmailRequired.controltovalidate = "MainContent_RegisterUser_CreateUserStepContainer_Email";
    MainContent_RegisterUser_CreateUserStepContainer_UniqueEmailRequired.errormessage = "Unique E-mail is required.";
    MainContent_RegisterUser_CreateUserStepContainer_UniqueEmailRequired.validationGroup = "RegisterUserValidationGroup";
    MainContent_RegisterUser_CreateUserStepContainer_UniqueEmailRequired.evaluationfunction = "CustomValidatorEvaluateIsValid";
    MainContent_RegisterUser_CreateUserStepContainer_UniqueEmailRequired.clientvalidationfunction = "ValidateUserMail";

```