Click here to Skip to main content
15,892,575 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi,
I am trying to use the following overloaded version of
C#
public RemoteAttribute(
    string routeName
)

.
I have registered the route as follows:
C#
routes.MapRoute(name: "remoteValidatorRoute",
            url: "{controller}/{action}/{id}", defaults:
            new { controller = "LoanProcessing", action = "TestSalaryHighest", id = UrlParameter.Optional });


and the following is the action defined in the controller:
 public class LoanProcessingController : Controller
    {
     
<pre lang="cs">public JsonResult TestSalaryHighest(int? salary)
      {
          return Json(salary&lt;10,
          JsonRequestBehavior.AllowGet);
      }</pre>

}

But the validtor is not working. I searched all over web , but did not find a single example which makes use of overloaded versions of RemoteValidator. Kindly help me with an example using overloaded versions of RemoteAttribute.
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900