How do i pass data from a Html.EditorFor to myAction in myController?
This is my Editor:
<div class="editor-label">
@Html.LabelFor(model => model.Quote_Currency)
</div>
<div class="editor-field">
@Html.EditorFor(model => model.Quote_Currency, new { })
@Html.ValidationMessageFor(model => model.Quote_Currency)
</div>
This is my controller action:
public ActionResult SaveQuote(FxQuote quote, string Quote_Currency)
{
objQuote.Quote_Currency = Quote_Currency;
dcfx.FxQuotes.InsertOnSubmit(quote);
dcfx.SubmitChanges();
return View();
Here,i was trying to have a parameter with the same name as my Editor but that did not work. Please help.
<form>? What do you see in the POST request?