读取XML相同节点的最后一个节点,循环读取赋值,最后一下赋值就是最后一个节点的值
XmlDocument doc = new XmlDocument();
doc.Load(System.Windows.Forms.Application.StartupPath + "/Resource/单体化/距离测量.xml");
XmlNodeList topM = doc.SelectNodes("/Measures/MeasureDistance3D/Item");
foreach (XmlElement element in topM)
{
points = element.GetElementsByTagName("Points")[0].InnerText;
}