Пример #1
0
        public void Sync()
        {
            _syncedCount  = 0;
            _deletedCount = 0;

            Load();

            if (_matches == null)
            {
                return;
            }

            if (_syncProfile.Length == 0)
            {
                Logger.Log("Must set a sync profile. This should be different on each user/computer you sync on.", EventType.Error);
                return;
            }

            _totalCount = _matches.Count;

            ContactsMatcher.SyncGroups(this);

            ContactsMatcher.SyncContacts(this);

            SaveContacts(_matches);
        }
Пример #2
0
        public void Load()
        {
            LoadOutlookContacts();
            LoadGoogleContacts();
            LoadGoogleGroups();

            try
            {
                _matches = ContactsMatcher.MatchContacts(this);
            }
            catch (DuplicateDataException ex)
            {
                Logger.Log(ex.Message, EventType.Error);
                if (DuplicatesFound != null)
                {
                    DuplicatesFound("Outlook duplicates found", ex.Message, EventType.Error);
                }
            }
        }