$(".empEdit").on("click", function () { var id = $(this).attr('id'); $("#dialog-edit").load("EditEmployee/" + id); $("#dialog-edit").dialog({ title: 'Employee Edit', height: 655, width: 400, modal: true, buttons: [{ id: "SubmitButton", text: "Update", click: function () { $.ajax({ type: "Post", url: "EditEmployee", data: "EmpId=" + $("#EmpId").val() + "&EmpName=" + $("#EmpName").val() + "&EmpSal=" + $("#EmpSal").val() + "&EmpContact=" + $("#EmpContact").val() + "&EmpGender=" + $("#EmpGender").val() + "&EmpDOJ=" + $("#EmpDOJ").val() + "&EmpDOB=" + $("#EmpDOB").val(), success: function (data) { var response = $(data); $("#empList").find("tr").eq(response.data("EmpId")).replaceWith(response); $("#dialog-edit").dialog("close"); }, error: function (data) { alert("Employee Updation Failed"); } }); } }] }); });
click: function () { $.ajax({ ...... ...... }); $("#dialog-edit").dialog("close");
click: function () { $.ajax({ ...... ...... }); $(this).dialog("close");
click: function () { $.ajax({ ...... ...... }); HERE PUT $('#UPDATEPANELID').HIDE(); $(this).dialog("close");
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)