protected void RaiseErrorEvent(DateTime timestamp, string errorMsg) { var errorCallback = new MrnErrorEventArgs() { TimeStamp = timestamp, ErrorMessage = errorMsg }; OnError(errorCallback); }
private void ProcessMrnErrorEvent(object sender, MrnErrorEventArgs e) { Dispatcher.BeginInvoke(new Action(() => { var msg = $"{e.TimeStamp} {e.ErrorMessage}"; MrnViewerDesktop.Title = $"{_windowsName} Error:: {msg}"; MessageBox.Show(msg); })); }
protected virtual void OnError(MrnErrorEventArgs e) { var handler = ErrorEvent; handler?.Invoke(this, e); }