問題:
Is there some easy way to handle multiple submit buttons from the same form?是否有一些簡單的方法可以處理來自同一表單的多個提交按鈕? For example:例如:
<% Html.BeginForm("MyAction", "MyController", FormMethod.Post); %>
<input type="submit" value="Send" />
<input type="submit" value="Cancel" />
<% Html.EndForm(); %>
Any idea how to do this in ASP.NET Framework Beta?知道如何在 ASP.NET Framework Beta 中執行此操作嗎? All examples I've googled for have single buttons in them.我用谷歌搜索過的所有示例中都有單個按鈕。
解決方案:
參考一: https://stackoom.com/question/1rAO參考二: How do you handle multiple submit buttons in ASP.NET MVC Framework?