I want to only compare the nodes of two xml files but not the value of the nodes using c#. If the node format in two files are not same then it should pop-up a message..
I will use Linq to XML :
XDocument doc = XDocument.Parse(data);
var list = doc.DescendantNodes().Where(i => i is XElement);
and then use this to compare :
foreach (var item in list)
if (((XElement)item).Name.LocalName == propert.Name)
but your final implementation should check number of nodes and other issues
Hope this helps...
Assuming that by "node format" you mean elements & their names, this will walk the element tree and compare the names: