protected void rptAccounts_ItemCommand(object source, RepeaterCommandEventArgs e) { switch (e.CommandName) { case "Del": string[] args = e.CommandArgument.ToString().Split(','); int empId = Convert.ToInt32(args[0]); string empAccount = args[1]; bool result = empAuth.DeleteEmployeeData(empId); //新增後端操作記錄 empAuth.InsertBackEndLogData(new BackEndLogData() { EmpAccount = c.GetEmpAccount(), Description = string.Format(".刪除帳號/Delete account .代碼/id[{0}] 帳號/account[{1}] 結果/result[{2}]", empId, empAccount, result), IP = c.GetClientIP() }); // log to file c.LoggerOfUI.InfoFormat("{0} deletes {1}, result: {2}", c.GetEmpAccount(), "Emp-" + empId.ToString() + "-" + empAccount, result); if (result) { DisplayAccounts(); } else { Master.ShowErrorMsg(Resources.Lang.ErrMsg_DeleteAccountFailed); } break; } }