{
ln_yj[i] = 1;
}
}
}
}
for (int i = 0; i <= ln_cdsl - 1; i++)
{
switch (lc_cd[i].Length)
{
case 1: //筛选出无执行命令的一级菜单数组,赋给新数组
foreach (var p in xmlFile.Elements("cdbm"))
{
if (p.Value.ToString() == lc_cd[i])
{
if ((string)p.Attribute("zxml") == "0")
{
lc_cd1[ln_cd1] = lc_cd[i];
ln_cd1 = ln_cd1 + 1;
}
}
}
break;
case 2: //筛选出无执行命令的二级菜单数组,赋给新数组
foreach (var p in xmlFile.Elements("cdbm"))
{
if (p.Value.ToString() == lc_cd[i])
{
if ((string)p.Attribute("zxml") == "0" &&
(string)p.Attribute("cdmc") != "-")
{
lc_cd2[ln_cd2] = lc_cd[i];
ln_cd2 = ln_cd2 + 1;
}
|