C# How to extract complete xml node set

后端 未结 4 541
名媛妹妹
名媛妹妹 2021-01-15 12:30

 
   
    Everyday Italian         


        
4条回答
  •  再見小時候
    2021-01-15 13:24

    Adding to Matthew's response:

    XmlDocument xDoc = new XmlDocument();
    // (Put code to populate xDoc here)
    XmlNodeList xNode = xDoc.SelectNodes(@"/bookstore/book[@category='COOKING']");
    

    xNode now equals Book of type COOKING.

提交回复
热议问题