protected void ListView_ItemCommand(object sender, ListViewCommandEventArgs e) { if (e.CommandName == "Remove") { e.Item.Visible = false; WattsALoanServiceReference.WattsALoanServiceClient client = new WattsALoanServiceReference.WattsALoanServiceClient(); client.DeleteEmployee(int.Parse(e.CommandArgument.ToString())); client.Close(); } else if (e.CommandName == "Edit") { string url = "~/Employee/Edit?id=" + e.CommandArgument; Response.Redirect(url); } }