Ajax.BeginForm with OnBegin prevent action to be called

后端 未结 1 1439
庸人自扰
庸人自扰 2021-01-11 15:31

I am using Ajax.Begin Form in my MVC 3 + Razor application

    using (Ajax.BeginForm(\"ActionName\", \"ControllerName\", new AjaxOptions { OnBegin = \"Valida         


        
1条回答
  •  囚心锁ツ
    2021-01-11 16:22

    found it !

    just had to tweak my OnBegin property to

    OnBegin = "return ValidateDateFunction('" + @abc.xyz + "')"
    

    Links I referred ASP.Net MVC 3.0 Ajax.ActionLink Onbegin Function true the execute the action?

    0 讨论(0)
提交回复
热议问题