public async Task <IActionResult> BindMemberTypes() { List <MemberTypeDTO> lstMemberTypeDTO = new List <MemberTypeDTO>(); try { lstMemberTypeDTO = await objmemtype.BindMemberType(Con); return(lstMemberTypeDTO != null && lstMemberTypeDTO.Count > 0 ? Ok(lstMemberTypeDTO) : (IActionResult)StatusCode(StatusCodes.Status204NoContent)); } catch (Exception) { return(StatusCode(StatusCodes.Status500InternalServerError)); throw; } }