Hello I am new to C # and I need to spend in the following function ( PostFilure ) in js a string variable from C # . The problem is that the function returns some object and I don't understand where comes from. Currently my code is;
Index.cshtml;@using (Ajax.BeginForm("Login", "Account", new AjaxOptions { HttpMethod = "post", OnBegin = "PostOnBegin", OnFailure = "PostFailure", OnSuccess = "PostSuccess", OnComplete = "PostOnComplete" })){...anylib.jsfunction PostFailure (message){}
the idea would be:Index.cshtml;@using (Ajax.BeginForm("Login", "Account", new AjaxOptions { HttpMethod = "post", OnBegin = "PostOnBegin", OnFailure = "PostFailure(messaje,'hola')", OnSuccess = "PostSuccess", OnComplete = "PostOnComplete" }))anylib.jsfunction PostFailure (message,x){}