private void OnNotifiedTraceMessage(string notificationMessage, Exception exception, NotificationSource notificationSource, TraceNotificationLevel notificationLevel)
        {
            string notificationMessageFinal = String.Format("{0} Error message is: '{1}'.", notificationMessage, exception.Message);

            OnNotifiedTraceMessage(new TraceNotificationEventArgs(notificationMessageFinal, notificationSource, notificationLevel));
        }
示例#2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TraceNotificationEventArgs"/> class.
 /// </summary>
 /// <param name="notificationMessage">The notification message.</param>
 /// <param name="notificationSource">The notification source.</param>
 /// <param name="notificationLevel">The notification level.</param>
 public TraceNotificationEventArgs(string notificationMessage, NotificationSource notificationSource, TraceNotificationLevel notificationLevel)
 {
     this.NotificationMessage = notificationMessage;
     this.NotificationSource  = notificationSource;
     this.NotificationLevel   = notificationLevel;
 }
 private void OnNotifiedTraceMessage(string notificationMessage, NotificationSource notificationSource, TraceNotificationLevel notificationLevel)
 {
     OnNotifiedTraceMessage(new TraceNotificationEventArgs(notificationMessage, notificationSource, notificationLevel));
 }