$('#ddlrole').change(funtion() { $('#namecheckbox').attr('checked','checked'); });
@Html.DropDownList("Roles", new SelectList((IEnumerable<EmployeeManagementSystem.DAO.RoleMaster>)ViewData["Roles"], "RoleId", "RoleName"), "Select Role", new { @id = "ddlrole", @class = "med m-wrap" }) @Html.CheckBox("CheckBox", new { id = "namecheckbox"})
$(document).ready(function () { $("#<%=ddlrole.ClientID%>").change(function () { $("#<%=namecheckbox.ClientID%>").prop('checked',true); });
$('#ddlrole').change(funtion() { $('#namecheckbox').get(0).checked = true; });
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)