I have an xml file and I am loading it in DataTable using DataSet.ReadXML. This XML has an internal DTD Defined. I thought DataTable.ReadXML Validates an XML before loading it in memory. Is it the case ?
Do I need to set some property within my dataset to make it validate Xml against the DTD Defined or Do I need to validate it using some othe XML class
<?xml version="1.0" standalone="yes"?>
<!DOCTYPE Resources [
<!ELEMENT Resources (Resource)+>
<!ELEMENT Resource (ResourceName,ResourceEmail)>
<!ELEMENT ResourceName (#PCDATA)>
<!ELEMENT ResourceEmail (#PCDATA)>
]>
<Resources>
<Resource>
<ResourceName>test</ResourceName>
<ResourceEmail>dfjfhg@fkjg.com</ResourceEmail>
</Resource>
</Resources>
You can use this code to validate your XML against a DTD