public void AddProfileAttribute(List <ProfileAttributeType> _listProfileAttributeType, Profile profile) { ProfileAttribute profileAttribute; foreach (ProfileAttributeType proAttributeType in _listProfileAttributeType) { profileAttribute = new ProfileAttribute(); profileAttribute.ProfileID = profile.ProfileID; profileAttribute.ProfileAttributeName = proAttributeType.Type; profileAttribute.ProfileAttributeTypeID = proAttributeType.ProfileAttributeTypeID; _profileAttributeService.SaveProfileAttribute(profileAttribute); } }