///<summary>Updates the text box that is displaying the current status of the Listener Service. Returns the status just in case other logic is needed outside of updating the status box.</summary> private eServiceSignalSeverity FillTextListenerServiceStatus() { eServiceSignalSeverity eServiceStatus = EServiceSignals.GetListenerServiceStatus(); if (eServiceStatus == eServiceSignalSeverity.Critical) { textListenerServiceStatus.BackColor = COLOR_ESERVICE_CRITICAL_BACKGROUND; textListenerServiceStatus.ForeColor = COLOR_ESERVICE_CRITICAL_TEXT; butStartListenerService.Enabled = true; } else if (eServiceStatus == eServiceSignalSeverity.Error) { textListenerServiceStatus.BackColor = COLOR_ESERVICE_ERROR_BACKGROUND; textListenerServiceStatus.ForeColor = COLOR_ESERVICE_ERROR_TEXT; butStartListenerService.Enabled = true; } else { textListenerServiceStatus.BackColor = SystemColors.Control; textListenerServiceStatus.ForeColor = SystemColors.WindowText; butStartListenerService.Enabled = false; } textListenerServiceStatus.Text = eServiceStatus.ToString(); return(eServiceStatus); }
///<summary>Sets IsProcessed to true on all eService signals of the passed in severity.</summary> public static void ProcessSignalsForSeverity(eServiceSignalSeverity severity) { if (RemotingClient.RemotingRole == RemotingRole.ClientWeb) { Meth.GetVoid(MethodBase.GetCurrentMethod(), severity); return; } string command = "UPDATE eservicesignal SET IsProcessed=1 WHERE Severity=" + POut.Int((int)severity); Db.NonQ(command); if (severity == eServiceSignalSeverity.Error) //Delete corresponding alert. { AlertItems.DeleteFor(AlertType.EConnectorError); } }