/// <summary>
/// 删除XML下的所有的数据
/// </summary>
/// <param name="path">xml文件及路径</param>
/// <param name="moduleName">模块名字</param>
private void DelXml(string path,string moduleName)
{
bool bSuccess = true;
while (bSuccess)
{
XmlDocument xmlDoc = new XmlDocument();
xmlDoc.Load(path);
XmlNodeList xnl = xmlDoc.SelectSingleNode(moduleName).ChildNodes;
int nCount = xnl.Count;
if (0 == nCount)
{
bSuccess = false;
}
for (int i = 0; i < xnl.Count; i++)
{
xnl[i].ParentNode.RemoveChild(xnl[i]);
}
xmlDoc.Save(path);
}
}