public Cart() { InitializeComponent(); if (Program.shoppingList.Count == 0) { this.checkedListBox1.Items.Add("Cart Empty!"); } else { this.checkedListBox1.Items.AddRange(ListFunctions.CheckListArrayMaker(Program.shoppingList)); } }
private void FinalTransaction() { sum = ListFunctions.GetSumOfShoppingList(Program.shoppingList); if (double.TryParse(textBox1.Text, out cash) && cash > sum) { change = cash - sum; //add new form and finish this method MessageBox.Show("Thank you for your payment."); System.Threading.Thread t = new System.Threading.Thread(new System.Threading.ThreadStart(ThreadProc2)); t.Start(); this.Close(); } else { textBox1.Clear(); MessageBox.Show("Invalid entry! Please try again."); } }
public FinalCheckout() { InitializeComponent(); this.richTextBox1.Text = ListFunctions.FinalCheckoutWriter(Program.shoppingList); }
public Final() { InitializeComponent(); richTextBox1.Text = ListFunctions.ReceiptWriter(Program.shoppingList); }
private void button29_Click(object sender, EventArgs e) { MessageBox.Show(ListFunctions.DescriptionWriter(14, Program.products)); }
public Cash() { InitializeComponent(); textBox2.Text = $"Enter cash amount > ${ListFunctions.GetSumOfShoppingList(Program.shoppingList):0.00}"; }
private void button1_Click(object sender, EventArgs e) { ListFunctions.RemoveFromList(ref Program.shoppingList, ref checkedListBox1); }