Exemplo n.º 1
0
 protected void StartUp()
 {
     if (!InternetAvailable.PingNetwork("adbmftp.ADBM.com"))
     {
         Sleep(Convert.ToInt32(60000 * Convert.ToDecimal(ConfigurationManager.AppSettings["SyncSleepMinutes"])));
     }
     //List<string> xxx = ADBMInterface.pathToADB();
     //ClearTransferFolders();
     //OnDemand();
     SyncChangedAttachmentFolders();
     //SyncThisFolder(1, 2);
     Sleep(Convert.ToInt32(60000 * Convert.ToDecimal(ConfigurationManager.AppSettings["SyncSleepMinutes"])));  //milliseconds: 1000 = 1 second, 60000 = 1 minute, 3,600,000 = 1 hour
 }
Exemplo n.º 2
0
        private void InternetConnectionAvailableHandler(CustomEventArgs cea)
        {
            internetStatus  = true;
            retriesExceeded = false;

            if (retryCount > 0)
            {
                InternetAvailable.Raise(this, null);
                #if (ENABLE_PUBNUB_LOGGING)
                string cbMessage = string.Format("InternetConnectionAvailableHandler: Internet Connection Available.");
                this.PubNubInstance.PNLog.WriteToLog(cbMessage, PNLoggingMethod.LevelInfo);
                #endif
            }
            retryCount = 0;
        }