private string CreateAppcode() { string appcode = Security.CreateAppcode(); _CustomerRepo = new CustomerRepo(); Customer item = _CustomerRepo.GetByAppcode(appcode); if (item != null) CreateAppcode(); return appcode; }