/// <summary> /// Button AddBrand Executes this Methos. Assign the string from BrandName Textfield to the BrandModel. /// BrandName and save the Brand in the Database. /// </summary> public void AddBrand() { LogHelper.WriteToLog("Brand creation started", LogState.Debug); Brand = new BrandModel(); Brand.BrandName = BrandName; Brand = SqliteDataAccess.AddBrand(Brand); EventAggregationProvider.EventAggregator.PublishOnUIThread(Brand); if (Brand != null && Brand.BrandName != "") { LogHelper.WriteToLog("Brand created", LogState.Info); } TryClose(); }