@using (Html.BeginForm("Generated_PaySlip", "Home", FormMethod.Get)) { <fieldset> Months @Html.DropDownList("Month", "Select Date") Employee Name @Html.DropDownList("EmplID", "Select Name") <input type="submit" value="Submit" /> </fieldset> }
public ActionResult InfoFor_PaySlip() { var dates = (from ps in DataContext.MonthlyRecords select new {ps.Month }).Distinct(); ViewData["Month"] = new SelectList(dates, "Month", "Month"); var names = (from n in DataContext.HrEmployees select new { n.EmplID, n.EmplName }).Distinct(); ViewData["EmplID"] = new SelectList(names, "EmplID", "EmplName"); return View(); }
$('#Month').val()==""
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)