/// <summary> /// Outputs the validation of the XML /// </summary> /// <param name="sender"></param> /// <param name="args"></param> private static void ValidationHandler(object sender, ValidationEventArgs args) { Trace.WriteLine(args.ToString(),"NMLSeriliazer.ValidationHandler"); }
protected void ValidationEH(object sender, ValidationEventArgs args) { if (args.Severity == XmlSeverityType.Warning) { logger.Info("WARNING: "); } else if (args.Severity == XmlSeverityType.Error) { logger.Error("ERROR: "); } XmlSchemaComplexType source = args.Exception.SourceSchemaObject as XmlSchemaComplexType; logger.Info(args.ToString()); if (source != null) { logger.Info(string.Format(CultureInfo.InvariantCulture, "{0}", source.Name)); } }
private static void ValidationHandler(object sender, ValidationEventArgs args) { Debug.WriteLine(args.ToString()); }