I havve created a C# class representing an XSD using the XSD.exe tool. I use a valdiation code to check the consistency of the XML with the XSD. I got this working, but using another XML file causes exceptions.
The XML files are produced by an external program and I do not have access to the original code or to a published XSD.
During reading the XML during Deserialization I get an exception:
enter System.InvalidOperationException was unhandled
HResult=-2146233079 Message=Het XML-document (235, 17) contains an error.
The error is described as an attempt to convertt a string to a DateTime format (which cannt be a correct description).
I thougth (235,17) migt represent the location in the document, but this is not consistent with the call stack.
My question: can you help me with a good debugging strategy for this type of problems? I would like to know exactly at which line in the XML the exception occurs, but don't know how to do this.