//[SessionAuthorizeFilter(UserType.AdminUser)] public IHttpActionResult DeleteEmployee(int id) { string result = ""; if (id != 0) { try { string CreatedBy = GlobalFunction.getLoggedInUser(Request.Headers.GetValues("Token").First()); result = objEmployeeVM.DeleteEmplyee(id); } catch (Exception ex) { ErrorHandlerClass.LogError(ex); result = ex.Message; } } else { result = "Enter Valid Mandatory Fields"; } return(Ok(new { results = result })); }