public bool AddCustomer(Customer customer) { List <MobileOperator> mobileOperators = dataAccess.DisplayOperators(); foreach (MobileOperator operatorr in mobileOperators) { try { if (customer.OperatorId.OperatorId != 0) { DataAcces dataAccess1 = new DataAcces(); dataAccess1.AddCustomer(customer); } } catch (InValidOperatorIdException) { throw new InValidOperatorIdException("Enter valid operator id"); } } return(true); }