Tree node fixes when deleting nodes

This commit is contained in:
2010-01-15 17:05:41 +00:00
parent 61c9d01516
commit cdf14f6328
5 changed files with 120 additions and 82 deletions

View File

@@ -1078,7 +1078,7 @@ namespace VEPROMS.CSLA.Library
string number = (MyContent.Type >= 20000 ? Ordinal.ToString() + "." : ((MyContent.Number ?? "") == "" ? MyContent.Text : MyContent.Number));
ItemInfo parent = this;
while (parent.MyPrevious != null) parent = parent.MyPrevious;
if (parent.ItemPartCount == 0)
if (parent.ItemPartCount <= 0 || parent.ItemParts.Count == 0)
return null;
else
{