首页 > 代码库 > 递归删除问题
递归删除问题
private bool DeleteNode(string pguid)
{
try
{
// string strFguid = "";
IList<Jc_jcdxtflbmb> _list_Jc_jcdxtflbmb = _codePresenter.GetJc_jcdxtflbmbByPguid(pguid);
if (_list_Jc_jcdxtflbmb.Count != 0)
{
for (int i = 0; i < _list_Jc_jcdxtflbmb.Count; i++)
{
Jc_jcdxtflbmb _Jc_jcdxtflbmb = _list_Jc_jcdxtflbmb[i];
DeleteNode(_Jc_jcdxtflbmb.Fguid);
_codePresenter.Delete(_Jc_jcdxtflbmb.Fguid);
}
}
return true;
}
catch (System.Exception ex)
{
return false;
}
}