62,046
社区成员
发帖
与我相关
我的任务
分享
//读取主的单个配置
private string ReadBaseInfo(string funType)
{
XmlDocument xml = new XmlDocument();
xml.Load(path);
XmlNode tmp = xml.SelectSingleNode("Main").SelectSingleNode("BaseInfo");
if (tmp == null)
{
return "";
}
if (tmp.Attributes[funType] != null)
{
return tmp.Attributes[funType].Value;
}
return "";
}
object locker=new object();
....................
lock(locker)
{
读取文件;
}