private void buttonCreate_Click(object sender, EventArgs e) { CreateClass cc = new CreateClass(); cc.ShowDialog(); string[] splits = cc.filepath.Split('\\'); string name = splits[splits.Length - 1]; name = name.Substring(0, name.Length - 4); ClassData cd; cd.name = name; cd.path = cc.filepath; Properties.Settings.Default.FilePath.Add(cc.filepath); Properties.Settings.Default.Classes.Add(name); Properties.Settings.Default.Save(); this.classes.Add(cd); this.comboBoxClass.Items.Add(cd); this.comboBoxClass.Refresh(); Class ctemp = new Class(cd.path); ctemp.Save(); return; }