private void storeHROfficerClerk(string SPName) { string empID = txtEmployeeID.Text.Trim(); try { EmployeeManager employeeManager = new EmployeeManager(); TransactionResponse response = employeeManager.AddHROfficerOrClerk(SPName, empID); if (response.isSuccessful()) { //show sucessfull message. msgPanel.Visible = true; SucessDIV.Visible = true; lblSuccessMessage.Text = response.getMessage(); } else { msgPanel.Visible = true; SucessDIV.Visible = true; lblSuccessMessage.Text = response.getMessage(); } } catch (Exception ex) { msgPanel.Visible = true; ErroroDIV.Visible = true; lblErrorMsg.Text = ex.ToString(); } }