I have a form in ASP.Net and razor.
I need to have two ways of submitting said form: one that goes through the Edit
action, and another that goes through the Validate
action.
How should I go about doing this?
I don't mind using JavaScript for this.
EDIT:
Using the custom attribute I get this error.
question from:https://stackoverflow.com/questions/16479946/asp-net-mvc-4-form-with-2-submit-buttons-actionsThe current request for action 'Resultados' on controller type 'InspecoesController' is ambiguous between the following action methods: System.Web.Mvc.ActionResult Validar(System.Collections.Generic.ICollection
1[Waveform.IEP.Intus.Server.Web.ViewModels.ResultadoViewModel]) on type Waveform.IEP.Intus.Server.Web.Controllers.InspecoesController System.Web.Mvc.ActionResult Resultados(System.Collections.Generic.ICollection
1[Waveform.IEP.Intus.Server.Web.ViewModels.ResultadoViewModel]) on type Waveform.IEP.Intus.Server.Web.Controllers.InspecoesController