diff --git a/EduNetworkBuilder/PersonClass.cs b/EduNetworkBuilder/PersonClass.cs index 8b45c7a..213910f 100644 --- a/EduNetworkBuilder/PersonClass.cs +++ b/EduNetworkBuilder/PersonClass.cs @@ -511,8 +511,7 @@ namespace EduNetworkBuilder /// public TreeNode WorkTree(TreeNode theTop=null, bool ForTeacher = false) { - //Sort by due date, and within the due dates, sort by save date - //Projects.Sort((q, p) => p.DueDate == q.DueDate ? p.SaveDate.CompareTo(q.SaveDate) : p.DueDate.CompareTo(q.DueDate)); + //Sort by due date, and within the due dates, sort by save date Projects.Sort((q, p) => p.Compare(q)); List DrawFrom = new List(); diff --git a/EduNetworkBuilder/PersonProfileForm.cs b/EduNetworkBuilder/PersonProfileForm.cs index d17a90f..82fc1ce 100644 --- a/EduNetworkBuilder/PersonProfileForm.cs +++ b/EduNetworkBuilder/PersonProfileForm.cs @@ -292,7 +292,10 @@ namespace EduNetworkBuilder Node.Tag = "Class"; //Do not translate this TreeNode Top = Node; tvClasswork.Nodes.Add(Node); - CurrentUser.Projects.Sort((q, p) => p.Compare(q)); + + //This is sorted reverse from what happens in PersonClass.WorkTree. + //In PersonClass.WorkTree, we traverse it backwards. + CurrentUser.Projects.Sort((p, q) => p.Compare(q)); foreach (SchoolworkClass SWC in CurrentUser.Projects) { Node = new TreeNode(SWC.Name);