Ejemplo n.º 1
0
        private void scrp_ScriptingError(object sender, ScriptingErrorEventArgs e)
        {
            string error = "- Error: " + e.InnerException.Message;

            error = error + (e.InnerException.InnerException != null ? "." + e.InnerException.InnerException.Message : String.Empty);

            _recentErrors.AppendLine(error);
        }
        private void ScripterScriptingError(object sender, ScriptingErrorEventArgs e)
        {
            this.CancellationToken.ThrowIfCancellationRequested();

            Logger.Write(
                TraceEventType.Verbose,
                string.Format(
                    "Sending scripting error progress event, Urn={0}, OperationId={1}, Completed={2}, Error={3}",
                    e.Current,
                    this.OperationId,
                    false,
                    e?.InnerException?.ToString() ?? "null"));

            this.SendProgressNotificationEvent(new ScriptingProgressNotificationParams
            {
                ScriptingObject = e.Current?.ToScriptingObject(),
                Status          = "Failed",
                ErrorMessage    = e?.InnerException?.Message,
                ErrorDetails    = e?.InnerException?.ToString(),
            });
        }
Ejemplo n.º 3
0
 static void scripter_ScriptingError(object sender, ScriptingErrorEventArgs e)
 {
     Console.WriteLine("Error: {0}", e.Current);
 }
Ejemplo n.º 4
0
 static void scripter_ScriptingError(object sender, ScriptingErrorEventArgs e)
 {
     Console.WriteLine("Error: {0}", e.Current);
 }
Ejemplo n.º 5
0
 private void Scripter_ScriptingError(object sender, ScriptingErrorEventArgs e)
 {
     TraceService.Error($"Error scripting {e.Current.Value}. {e.InnerException.ToString()}");
 }