diff --git a/EduNetworkBuilder/PersonProfileForm.cs b/EduNetworkBuilder/PersonProfileForm.cs index 31e1c13..b4a3ab9 100644 --- a/EduNetworkBuilder/PersonProfileForm.cs +++ b/EduNetworkBuilder/PersonProfileForm.cs @@ -153,7 +153,7 @@ namespace EduNetworkBuilder { //We have a class tree Node = new TreeNode(NB.Translate("PPF_Class")); - Node.Tag = "Class"; + Node.Tag = "Class"; //Do not translate this TreeNode Top = Node; tvClasswork.Nodes.Add(Node); foreach(SchoolworkClass SWC in CurrentUser.Projects) @@ -164,7 +164,7 @@ namespace EduNetworkBuilder } //we have a students tree Node = new TreeNode(NB.Translate("PPF_Students")); - Node.Tag = "Students"; + Node.Tag = "Students"; //Do not translate this tvClasswork.Nodes.Add(Node); } } @@ -238,6 +238,14 @@ namespace EduNetworkBuilder ChangeTreeDataTab(TreeDataTab.homeworktab); UpdateFormFromSchoolwork(SWC); } + if(Node.Tag is string) + { + string Selected = (string)Node.Tag; + if (Selected == "Class") //Do not translate this + ChangeTreeDataTab(TreeDataTab.classtab); + if (Selected == "Students") //Do not translate this + ChangeTreeDataTab(TreeDataTab.studenttab); + } } void SaveSchoolworkDataFromForm(object sender, EventArgs e)