/// <summary> /// If <paramref name="currentProduct"/> is not null or whitespace, attempt to insert that product to DB. /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void BtnTrackItem_Click(object sender, EventArgs e) { if (!string.IsNullOrWhiteSpace(currentProduct.Product_ID.ToString())) { DB_Manager.InsertProduct(currentProduct); } }
/// <summary> /// Whenever we browse the addresses and the stores available at that address, insert the address and the stores in the DB /// </summary> /// <param name="sender"></param> /// <param name="e">The object containing the address and available stores</param> private void FormMain_ReportAvailableStoresEvent(object sender, Shipt_Available_Stores e) { if (e.StoreNames.Count > 0) { DB_Manager.InsertAddress(e.Delivery_Address); DB_Manager.InsertStores(e); } }
private void FormTrackedProducts_Shown(object sender, EventArgs e) { string testString = ""; DB_Manager.ReadProducts(testString); }