C
CGuy
Hi,
I am using an XmlTextReader to read an xml file. It may happen that the
file is present in the disk, but it may be empty (0 bytes). I would like to
find out whether the xml file contains a valid root node or not. How do I do
this?
This is what I need
if(File.Exists(fileName))
{
XmlTextReader xmReader = new XmlTextReader(fileName);
//How do I find out whether this xml document contains a Root node named
"ROOT_NODE" or not?
}
CGuy
I am using an XmlTextReader to read an xml file. It may happen that the
file is present in the disk, but it may be empty (0 bytes). I would like to
find out whether the xml file contains a valid root node or not. How do I do
this?
This is what I need
if(File.Exists(fileName))
{
XmlTextReader xmReader = new XmlTextReader(fileName);
//How do I find out whether this xml document contains a Root node named
"ROOT_NODE" or not?
}
CGuy