public static void HandleXML() { XmlDocument xmldoc = new XmlDocument(); xmldoc.Load("C:\\11.xml"); XmlNode xnRoot = xmldoc.SelectSingleNode("Resp"); XmlNodeList nodelist = xnRoot.ChildNodes; foreach (XmlNode node in nodelist) { string Msg=node.SelectSingleNode("Msg").InnerXml; if (Msg !="") { //在此Msg 就是你想要的值 Console.WriteLine(Msg); } } } 版本号 状态码 返回消息