Esempio n. 1
0
 /// <summary>
 /// Adds the main category.
 /// </summary>
 private void AddMainCategory(){
   if (txtMainCategory.Text != "") {
     MainCategories mainCategory       = new MainCategories();
     mainCategory.GUID                 = Utilities.GetNewGUID();
     mainCategory.Category             = txtMainCategory.Text;
     _categoriesControl.AddMainCategory(mainCategory);
   }
   PopulateCategories();
 }
Esempio n. 2
0
 /// <summary>
 /// Adds a main category.
 /// </summary>
 /// <param name="mainCategory">The main category.</param>
 public void AddMainCategory(MainCategories mainCategory){
   Persistence.Persist.Data.MainCategoriesList.Add(mainCategory);
   Persist();
 }