In an XML file such as :
code goes here
XDocument doc = XDocument.Load("input.xml");
var q = from node in doc.Descendants("Snippet")
let attr = node.Attribute("name")
where attr != null && attr.Value == "abc"
select node;
q.ToList().ForEach(x => x.Remove());
doc.Save("output.xml");
.Net 2.0
XmlDocument doc = new XmlDocument();
doc.Load("input.xml");
XmlNodeList nodes = doc.SelectNodes("//Snippet[@name='abc']");
Now you have the nodes whose attribute name='abc', you can now loop through it and delete