Ejemplo n.º 1
0
 private void StartFullSync(object direction)
 {
     if (Monitor.TryEnter(ContactSync.SynchRoot))
     {
         try
         {
             Config.Direction dir = (Config.Direction)direction;
             ContactSync      cs  = new ContactSync(Config.Username, Config.Password, Convert.ToInt32(Config.Interval * 60000));
             cs.GoogleSynched  += GoogleSynched;
             cs.OutlookSynched += OutlookSynched;
             cs.StartSynching  += StartSynching;
             cs.EndSynching    += EndSynching;
             cs.Error          += SynchError;
             cs.FullSync(dir);
         }
         finally
         {
             Monitor.Exit(ContactSync.SynchRoot);
         }
     }
     else
     {
         MessageBox.Show("Sync in progress... cannot run full sync");
     }
 }
Ejemplo n.º 2
0
        private void StartThread()
        {
            ContactSync cs = new ContactSync(Config.Username, Config.Password, Convert.ToInt32(Config.Interval * 60000));

            cs.GoogleSynched  += GoogleSynched;
            cs.OutlookSynched += OutlookSynched;
            cs.StartSynching  += StartSynching;
            cs.EndSynching    += EndSynching;
            cs.Error          += SynchError;
            cs.SyncFromGoogle();
        }
Ejemplo n.º 3
0
 private void StartThread()
 {
     ContactSync cs = new ContactSync(Config.Username, Config.Password,Convert.ToInt32(Config.Interval*60000));
     cs.GoogleSynched += GoogleSynched;
     cs.OutlookSynched += OutlookSynched;
     cs.StartSynching += StartSynching;
     cs.EndSynching += EndSynching;
     cs.Error += SynchError;
     cs.SyncFromGoogle();
 }
Ejemplo n.º 4
0
 private void StartFullSync(object direction)
 {
     if (Monitor.TryEnter(ContactSync.SynchRoot))
     {
         try
         {
             Config.Direction dir = (Config.Direction)direction;
             ContactSync cs = new ContactSync(Config.Username, Config.Password, Convert.ToInt32(Config.Interval * 60000));
             cs.GoogleSynched += GoogleSynched;
             cs.OutlookSynched += OutlookSynched;
             cs.StartSynching += StartSynching;
             cs.EndSynching += EndSynching;
             cs.Error += SynchError;
             cs.FullSync(dir);
         }
         finally
         {
             Monitor.Exit(ContactSync.SynchRoot);
         }
     }
     else
         MessageBox.Show("Sync in progress... cannot run full sync");
 }