private void RegisterNewAward() { AwardForm form = new AwardForm(); if (form.ShowDialog(this) == DialogResult.OK) { awards.Add(form.Title, form.Description); DisplayAwards(); } }
public ActionResult Create(FormCollection collection) { try { awards.Add(new Award(collection["Title"], collection["Description"])); return(RedirectToAction("Index")); } catch { return(View()); } }
public ActionResult Create(FormCollection collection) { try { awards.Add(new Award(collection["Титул"], collection["Описание"])); return(RedirectToAction("Список")); } catch { return(View()); } }