i have a large XML document that is to large to be loaded using XmlDocument. i need to go through each child of a node and check it agaisnt a condition, then delete accordingly , then finally save the document.
<root>
<node id="1">
<child delete="false"/>
</node>
<node id="2">
<child delete="true"/>
</node>
</root>
for example i would want to delete node 2, and this process must be repeated hundreds of times.
any help would be appreciated.
thanks.
Edit
could someone explain how i might go about doing this.
You can use an XmlReader to sequentially read your xml (
ReadOuterXmlmight be useful in your case to read a whole node at a time). Then use an XmlWriter to write out all the nodes you want to keep.