I'm trying to compare two PowerPoint presentations at XML level to find the difference between a hidden shape and a visible shape.
For that I'm using the name space Microsoft.XmlDiffPatch
and XmlDiff
property.
But while invoking the compare function I got the error
System.Xml.XmlException: 'Data at the root level is invalid. Line 1, position 1.'
How can I get rid of this type of error? And why do get this error?
Here is my code :
XmlDiff xmldiff = new XmlDiff(XmlDiffOptions.IgnoreChildOrder|
XmlDiffOptions.IgnoreNamespaces|
XmlDiffOptions.IgnorePrefixes|
XmlDiffOptions.IgnoreWhitespace|
XmlDiffOptions.IgnoreComments|
XmlDiffOptions.IgnoreXmlDecl);
var Result =
xmldiff.Compare(XmlReader.Create(@"C:\Users\MySystemDoc\Test\TestSlide1.pptx"),
XmlReader.Create(@"C:\Users\MySystemDoc\Test\TestSlide2.pptx"));
Thanks in advance.