Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Linq;
- using System.Text;
- using System.Windows.Forms;
- using System.Runtime.InteropServices;
- using MySql.Data.MySqlClient;
- using System.IO;
- using System.Threading.Tasks;
- namespace triplang
- {
- public partial class pane : Form
- {
- MySqlConnection connection = new MySqlConnection("datasource=localhost;port=3306;username=root;password=");
- MySqlCommand command;
- MySqlDataAdapter da;
- int cheeseburgerM = 46;
- int cheeseburgerL = 65;
- int mcmuffinA = 70;
- int mcmuffinmeal = 90;
- int mcmuffinL = 118;
- int mccafesmall = 31;
- int mccafemedium = 41;
- //burgers
- int bigmacM = 134;
- int bigmacL = 202;
- int mcspicyM = 96;
- int mcspicyL = 136;
- int bigntastyM = 140;
- int bigntastyL = 170;
- int burgerM = 36;
- int burgerL = 48;
- //fries
- int friesR = 33;
- int friesM = 55;
- int friesL = 67;
- //fries Shake shake
- int shakeR = 60;
- int shakeM = 70;
- int applepie = 29;
- double dc = 0.95;
- //
- int mcspicybundleM = 155;
- int mcspicybundleL = 172;
- int bigntastybundleM = 185;
- int bigntastybundleL = 205;
- int bigmcbundleM = 185;
- int bigmcbundleL = 202;
- //
- int capuccinoS = 75;
- int capuccinoM = 85;
- int mccoffefloat = 55;//
- int spritemedium = 28;
- int spritelarge = 38;
- int cokefloat = 28;
- int cokefloatlarge = 38;
- int chickmcdo2 = 152;
- int mcnuggets10 = 156;
- int cmfries = 154;
- int chicsphag = 126;
- int mcsaverspaghetti = 92;
- int mediumfillet = 67;
- int largefillet = 72;
- int filletrice = 57;
- int spRice = 110;
- int chicken = 96;
- int cheesyeggdesal = 92;
- int hotcake = 90;
- int nbreakfast = 128;
- int a = 1;
- int b = 2;
- int c = 3;
- int d = 4;
- int E = 5;
- private Size? _mouseGrabOffset;
- [DllImport("Gdi32.dll", EntryPoint = "CreateRoundRectRgn")]
- private static extern IntPtr CreateRoundRectRgn
- (
- int nLeftRect,
- int nTopRect,
- int nRightRect,
- int nBottomRect,
- int nWidthEllipse,
- int nHeightEllipse
- );
- const int WS_MINIMIZEBOX = 0x20000;
- const int CS_DBLCLKS = 0x8;
- protected override CreateParams CreateParams
- {
- get
- {
- CreateParams cp = base.CreateParams;
- cp.Style |= WS_MINIMIZEBOX;
- cp.ClassStyle |= CS_DBLCLKS;
- return cp;
- }
- }
- public pane()
- {
- InitializeComponent();
- this.FormBorderStyle = FormBorderStyle.None;
- Region = System.Drawing.Region.FromHrgn(CreateRoundRectRgn(0, 0, Width, Height, 20, 20));
- gg();
- }
- protected override void OnMouseDown(MouseEventArgs e)
- {
- if (e.Button == System.Windows.Forms.MouseButtons.Left)
- _mouseGrabOffset = new Size(e.Location);
- base.OnMouseDown(e);
- }
- protected override void OnMouseUp(MouseEventArgs e)
- {
- _mouseGrabOffset = null;
- base.OnMouseUp(e);
- }
- protected override void OnMouseMove(MouseEventArgs e)
- {
- if (_mouseGrabOffset.HasValue)
- {
- this.Location = Cursor.Position - _mouseGrabOffset.Value;
- }
- base.OnMouseMove(e);
- }
- private void pane_Load(object sender, EventArgs e)
- {
- this.php1.Hide();
- f4.Hide(); f5.Hide(); f6.Hide();
- this.discounttext.Hide();
- this.label13.Hide();
- this.ORNUMBER.Hide();
- this.friess1.Hide();
- this.friess2.Hide();
- this.friess3.Hide();
- this.friess4.Hide();
- this.friess5.Hide();
- this.applepiee.Hide();
- this.burgerr1.Hide();
- this.burgerr2.Hide();
- this.burgerr3.Hide();
- this.burgerr4.Hide();
- this.burgerr5.Hide();
- this.cafee4.Hide();
- this.cafee1.Hide();
- this.cafee3.Hide();
- this.cafee5.Hide();
- this.idnumberr.Text = Form2.setvalueforid;
- this.idnumberr.Hide();
- comboBox1.Hide();
- Q1.Hide(); Q3.Hide(); Q5.Hide(); Q7.Hide(); size1.Hide();
- Q8.Hide();
- this.sample.Hide();
- comboBox24.Hide(); comboBox22.Hide(); comboBox20.Hide(); comboBox18.Hide(); comboBox16.Hide();
- this.dateTimePicker1.Hide();
- cashier.Text = login.setvalueforusername;
- listView1.View = View.Details;
- listView1.FullRowSelect = true;
- listView1.Columns.Add("Order", 75);
- listView1.Columns.Add("Quantity", 75);
- listView1.Columns.Add("Size", 75);
- listView1.Columns.Add("Price", 75);
- tabControl1.Appearance = TabAppearance.FlatButtons;
- tabControl1.ItemSize = new Size(0, 1);
- tabControl1.SizeMode = TabSizeMode.Fixed;
- breakfast.TabStop = false;
- breakfast.FlatStyle = FlatStyle.Flat;
- breakfast.FlatAppearance.BorderColor = Color.DarkRed;
- lunch.TabStop = false;
- lunch.FlatStyle = FlatStyle.Flat;
- lunch.FlatAppearance.BorderColor = Color.DarkRed;
- valuemeal.TabStop = false;
- valuemeal.FlatStyle = FlatStyle.Flat;
- valuemeal.FlatAppearance.BorderColor = Color.DarkRed;
- drinks.TabStop = false;
- drinks.FlatStyle = FlatStyle.Flat;
- drinks.FlatAppearance.BorderColor = Color.DarkRed;
- mccafe.TabStop = false;
- mccafe.FlatStyle = FlatStyle.Flat;
- mccafe.FlatAppearance.BorderColor = Color.DarkRed;
- bestseller.TabStop = false;
- bestseller.FlatStyle = FlatStyle.Flat;
- bestseller.FlatAppearance.BorderColor = Color.DarkRed;
- }
- public void gg()
- {
- String selectQuery = "SELECT * FROM empaccount.productinfo";
- command = new MySqlCommand(selectQuery, connection);
- da = new MySqlDataAdapter(command);
- DataTable table = new DataTable();
- da.Fill(table);
- if (table.Rows.Count > 0)
- {
- bes1.Text = table.Rows[0][0].ToString();
- label2.Text = table.Rows[0][1].ToString();
- byte[] img = (byte[])table.Rows[0][2];
- MemoryStream ms = new MemoryStream(img);
- pictureBox8.Image = Image.FromStream(ms);
- }
- if (table.Rows.Count > 1)
- {
- bes2.Text = table.Rows[1][0].ToString();
- label14.Text = table.Rows[1][1].ToString();
- byte[] img2 = (byte[])table.Rows[1][2];
- MemoryStream ms2 = new MemoryStream(img2);
- pictureBox14.Image = Image.FromStream(ms2);
- }
- if (table.Rows.Count > 2)
- {
- label10.Text = table.Rows[2][0].ToString();
- label11.Text = table.Rows[2][1].ToString();
- byte[] img3 = (byte[])table.Rows[2][2];
- MemoryStream ms3 = new MemoryStream(img3);
- pictureBox3.Image = Image.FromStream(ms3);
- }
- da.Dispose();
- }
- private void add(string Order, string Quantity, String Size, String Price)
- {
- String[] row = { Order, Quantity, Size, Price };
- ListViewItem item = new ListViewItem(row);
- listView1.Items.Add(item);
- }
- private void label3_Click(object sender, EventArgs e)
- {
- Environment.Exit(0);
- }
- private void menuStrip1_ItemClicked(object sender, ToolStripItemClickedEventArgs e)
- {
- }
- private void loginToolStripMenuItem_Click(object sender, EventArgs e)
- {
- adminlogin frm = new adminlogin();
- frm.Show();
- this.Hide();
- }
- private void button2_Click(object sender, EventArgs e)
- {
- }
- private void pauseNewPOSToolStripMenuItem_Click(object sender, EventArgs e)
- {
- }
- private void logoutToolStripMenuItem_Click(object sender, EventArgs e)
- {
- logout exe = new logout();
- exe.Show();
- this.Close();
- }
- private void pictureBox2_Click(object sender, EventArgs e)
- {
- comboBox1.Show();
- }
- private void button2_Click_1(object sender, EventArgs e)
- {
- if (comboBox1.SelectedItem == null)
- {
- MessageBox.Show("Please select an item", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- if (comboBox1.SelectedItem != null)
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(ChickenBF.Text, comboBox1.Text, reg1.Text, price1.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- }
- private void button1_Click_1(object sender, EventArgs e)
- {
- if (listView1.Items.Count <= 0)
- {
- MessageBox.Show("Please select an item first", "Error", MessageBoxButtons.OK, MessageBoxIcon.Warning);
- }
- else if (total.Text == "0")
- {
- MessageBox.Show("Get the total first", "POS", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else if (string.IsNullOrEmpty(amount.Text))
- {
- MessageBox.Show("Enter an amount first", "POS", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else if (Convert.ToDouble(amount.Text) < Convert.ToDouble(total.Text))
- {
- MessageBox.Show("Not enough money.", "Error", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else if (change.Text == "0")
- {
- MessageBox.Show("Process it first", "POS", MessageBoxButtons.OK, MessageBoxIcon.Warning);
- }
- else
- {
- foreach (ListViewItem li in listView1.Items)
- {
- string condense = "datasource=localhost;port=3306;username=root;password=''";
- string milk = "insert into empaccount.sales(ORNUMBER,Cashier,Orders,Quantity,Size,Price,AMOUNT,Returnn,Discount,Date) values ('" + this.ORNUMBER.Text + "','" + cashier.Text + "','" + li.SubItems[0].Text + "','" + li.SubItems[1].Text + "','" + li.SubItems[2].Text + "','" + li.SubItems[3].Text + "','" + this.amount.Text + "','" + this.change.Text + "','" + this.discount1.Text + "','" + this.dateTimePicker1.Value + "');";
- MySqlConnection conDatabase = new MySqlConnection(condense);
- MySqlCommand cmdDatabase = new MySqlCommand(milk, conDatabase);
- MySqlDataReader myReader;
- if (string.IsNullOrEmpty(cashier.Text))
- {
- MessageBox.Show("Please fill the Notes. ", "Error!", MessageBoxButtons.OK, MessageBoxIcon.Warning);
- }
- if (listView1.Items.Count < 0)
- {
- MessageBox.Show("Please order first", "Error", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else
- {
- conDatabase.Open();
- myReader = cmdDatabase.ExecuteReader();
- while (myReader.Read())
- {
- }
- }
- }
- MessageBox.Show("Your order has been added susccessfully", "POS", MessageBoxButtons.OK, MessageBoxIcon.Information);
- PRINT frm = new PRINT();
- frm.cashier.Text = cashier.Text.ToString();
- frm.idnumber.Text = idnumberr.Text.ToString();
- frm.ornumber.Text = ORNUMBER.Text.ToString();
- frm.datevalue.Text = dateTimePicker1.Value.ToString();
- frm.total.Text = total.Text.ToString();
- frm.amount.Text = amount.Text.ToString();
- frm.change.Text = change.Text.ToString();
- frm.discount.Text = discount1.Text.ToString();
- for (int i = 0; i < listView1.Items.Count; i++)
- {
- frm.item1.Text = listView1.Items[0].SubItems[0].Text.ToString();
- frm.qt1.Text = listView1.Items[0].SubItems[1].Text.ToString();
- frm.size1.Text = listView1.Items[0].SubItems[2].Text.ToString();
- frm.price1.Text = listView1.Items[0].SubItems[3].Text.ToString();
- if (listView1.Items.Count > 1)
- {
- frm.item2.Text = listView1.Items[1].SubItems[0].Text.ToString();
- frm.qt2.Text = listView1.Items[1].SubItems[1].Text.ToString();
- frm.size2.Text = listView1.Items[1].SubItems[2].Text.ToString();
- frm.price2.Text = listView1.Items[1].SubItems[3].Text.ToString();
- }
- if (listView1.Items.Count > 2)
- {
- //row3
- frm.item3.Text = listView1.Items[2].SubItems[0].Text.ToString();
- frm.qt3.Text = listView1.Items[2].SubItems[1].Text.ToString();
- frm.size3.Text = listView1.Items[2].SubItems[2].Text.ToString();
- frm.price3.Text = listView1.Items[2].SubItems[3].Text.ToString();
- }
- if (listView1.Items.Count > 3)
- {
- //row4
- frm.item4.Text = listView1.Items[3].SubItems[0].Text.ToString();
- frm.qt4.Text = listView1.Items[3].SubItems[1].Text.ToString();
- frm.size4.Text = listView1.Items[3].SubItems[2].Text.ToString();
- frm.price4.Text = listView1.Items[3].SubItems[3].Text.ToString();
- }
- //row5
- if (listView1.Items.Count > 4)
- {
- frm.item5.Text = listView1.Items[4].SubItems[0].Text.ToString();
- frm.qt5.Text = listView1.Items[4].SubItems[1].Text.ToString();
- frm.size5.Text = listView1.Items[4].SubItems[2].Text.ToString();
- frm.price5.Text = listView1.Items[4].SubItems[3].Text.ToString();
- }
- if (listView1.Items.Count > 5)
- // row6
- {
- frm.item6.Text = listView1.Items[5].SubItems[0].Text.ToString();
- frm.qt6.Text = listView1.Items[5].SubItems[1].Text.ToString();
- frm.size6.Text = listView1.Items[5].SubItems[2].Text.ToString();
- frm.price6.Text = listView1.Items[5].SubItems[3].Text.ToString();
- }
- if (listView1.Items.Count > 6)
- {
- // row7
- frm.item7.Text = listView1.Items[6].SubItems[0].Text.ToString();
- frm.qt7.Text = listView1.Items[6].SubItems[1].Text.ToString();
- frm.size7.Text = listView1.Items[6].SubItems[2].Text.ToString();
- frm.price7.Text = listView1.Items[6].SubItems[3].Text.ToString();
- }
- // row8
- if (listView1.Items.Count > 7)
- {
- frm.item8.Text = listView1.Items[7].SubItems[0].Text.ToString();
- frm.qt8.Text = listView1.Items[7].SubItems[1].Text.ToString();
- frm.size9.Text = listView1.Items[7].SubItems[2].Text.ToString();
- frm.price8.Text = listView1.Items[7].SubItems[3].Text.ToString();
- }
- else
- {
- break;
- }
- }
- this.Hide();
- frm.Show();
- }
- }
- private void amount_KeyPress(object sender, KeyPressEventArgs e)
- {
- if (!char.IsControl(e.KeyChar) && !char.IsDigit(e.KeyChar) &&
- (e.KeyChar != '.'))
- {
- e.Handled = true;
- }
- // only allow one decimal point
- if ((e.KeyChar == '.') && ((sender as TextBox).Text.IndexOf('.') > -1))
- {
- e.Handled = true;
- }
- }
- private void button5_Click(object sender, EventArgs e)
- {
- tabControl1.SelectTab(4);
- }
- private void button4_Click_1(object sender, EventArgs e)
- {
- tabControl1.SelectTab(0);
- }
- private void panel1_Paint(object sender, PaintEventArgs e)
- {
- }
- private void button4_Click(object sender, EventArgs e)
- {
- if (Q1.SelectedItem == null)
- {
- MessageBox.Show("Please select an item", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(CEggdesal.Text, Q1.Text, reg2.Text, price2.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void Q1_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (Q1.SelectedIndex == 0)
- {
- Int32 haha = a * cheesyeggdesal;
- price2.Text = Convert.ToString(haha * 1.12);
- }
- if (Q1.SelectedIndex == 1)
- {
- Int32 haha = b * cheesyeggdesal;
- price2.Text = Convert.ToString(haha * 1.12);
- }
- if (Q1.SelectedIndex == 2)
- {
- Int32 haha = c * cheesyeggdesal;
- price2.Text = Convert.ToString(haha * 1.12);
- }
- if (Q1.SelectedIndex == 3)
- {
- Int32 haha = d * cheesyeggdesal;
- price2.Text = Convert.ToString(haha * 1.12);
- }
- if (Q1.SelectedIndex == 4)
- {
- Int32 haha = E * cheesyeggdesal;
- price2.Text = Convert.ToString(haha * 1.12);
- }
- }
- private void comboBox1_SelectedIndexChanged_1(object sender, EventArgs e)
- {
- if (comboBox1.SelectedIndex == 0)
- {
- Int32 haha = a * chicken;
- price1.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox1.SelectedIndex == 1)
- {
- Int32 haha = b * chicken;
- price1.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox1.SelectedIndex == 2)
- {
- Int32 haha = c * chicken;
- price1.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox1.SelectedIndex == 3)
- {
- Int32 haha = d * chicken;
- price1.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox1.SelectedIndex == 4)
- {
- Int32 haha = E * chicken;
- price1.Text = Convert.ToString(haha * 1.12);
- }
- }
- private void Q3_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (Q3.SelectedIndex == 0)
- {
- Int32 haha = a * hotcake;
- price3.Text = Convert.ToString(haha * 1.12);
- }
- if (Q3.SelectedIndex == 1)
- {
- Int32 haha = b * hotcake;
- price3.Text = Convert.ToString(haha * 1.12);
- }
- if (Q3.SelectedIndex == 2)
- {
- Int32 haha = c * hotcake;
- price3.Text = Convert.ToString(haha * 1.12);
- }
- if (Q3.SelectedIndex == 3)
- {
- Int32 haha = d * hotcake;
- price3.Text = Convert.ToString(haha * 1.12);
- }
- if (Q3.SelectedIndex == 4)
- {
- Int32 haha = E * hotcake;
- price3.Text = Convert.ToString(haha * 1.12);
- }
- }
- private void button5_Click_1(object sender, EventArgs e)
- {
- if (Q3.SelectedItem == null)
- {
- MessageBox.Show("Please select an item", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(hotcakee.Text, Q3.Text, reg3.Text, price3.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button3_Click(object sender, EventArgs e)
- {
- foreach (ListViewItem item in listView1.Items)
- if (item.Selected)
- {
- listView1.Items.Remove(item);
- change.Text = "0";
- total.Text = "0";
- }
- double value = 0;
- for (int i = 0; i < listView1.Items.Count; i++)
- {
- value += double.Parse(listView1.Items[i].SubItems[3].Text);
- }
- if (listView1.Items.Count == 0)
- {
- total.Text = "0";
- }
- }
- private void Q5_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (Q5.SelectedIndex == 0)
- {
- Int32 haha = a * nbreakfast;
- price4.Text = Convert.ToString(haha * 1.12);
- }
- if (Q5.SelectedIndex == 1)
- {
- Int32 haha = b * nbreakfast;
- price4.Text = Convert.ToString(haha * 1.12);
- }
- if (Q5.SelectedIndex == 2)
- {
- Int32 haha = c * nbreakfast;
- price4.Text = Convert.ToString(haha * 1.12);
- }
- if (Q5.SelectedIndex == 3)
- {
- Int32 haha = d * nbreakfast;
- price4.Text = Convert.ToString(haha * 1.12);
- }
- if (Q5.SelectedIndex == 4)
- {
- Int32 haha = E * nbreakfast;
- price4.Text = Convert.ToString(haha * 1.12);
- }
- }
- private void button6_Click(object sender, EventArgs e)
- {
- if (Q5.SelectedItem == null)
- {
- MessageBox.Show("Please select an item", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(NBreakfast.Text, Q5.Text, reg4.Text, price4.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void listView1_ColumnClick(object sender, ColumnClickEventArgs e)
- {
- double value = 0;
- for (int i = 0; i < listView1.Items.Count; i++)
- {
- value += double.Parse(listView1.Items[i].SubItems[3].Text);
- }
- total.Text = Convert.ToString(value);
- discounttext.Text = Convert.ToString(value);
- }
- private void tabPage1_Click(object sender, EventArgs e)
- {
- }
- private void button37_Click(object sender, EventArgs e)
- {
- if (string.IsNullOrEmpty(amount.Text))
- {
- MessageBox.Show("Please input the amount.", "Error", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else if (total.Text == "0")
- {
- MessageBox.Show("Please get the total first", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (Convert.ToDouble(amount.Text) < Convert.ToDouble(total.Text))
- {
- MessageBox.Show("You dont have enough money.", "Error", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else
- {
- Random slumpGenerator = new Random();
- int tal = slumpGenerator.Next(0, 98675434);
- ORNUMBER.Text = "10000" + tal.ToString();
- change.Text = (double.Parse(amount.Text) - double.Parse(total.Text)).ToString();
- }
- }
- private void pictureBox7_Click(object sender, EventArgs e)
- {
- size1.Show();
- Q8.Show();
- }
- private void button35_Click(object sender, EventArgs e)
- {
- tabControl1.SelectTab(2);
- }
- private void button34_Click(object sender, EventArgs e)
- {
- tabControl1.SelectTab(1);
- }
- private void button36_Click(object sender, EventArgs e)
- {
- tabControl1.SelectTab(3);
- }
- private void panel4_Paint(object sender, PaintEventArgs e)
- {
- }
- private void button33_Click_1(object sender, EventArgs e)
- {
- tabControl1.SelectTab(0);
- }
- private void button38_Click(object sender, EventArgs e)
- {
- tabControl1.SelectTab(4);
- }
- private void amount_TextChanged(object sender, EventArgs e)
- {
- }
- private void Q7_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (Q7.SelectedIndex == 0)
- {
- Int32 haha = a * spRice;
- price5.Text = Convert.ToString(haha * 1.12);
- }
- if (Q7.SelectedIndex == 1)
- {
- Int32 haha = b * spRice;
- price5.Text = Convert.ToString(haha * 1.12);
- }
- if (Q7.SelectedIndex == 2)
- {
- Int32 haha = c * spRice;
- price5.Text = Convert.ToString(haha * 1.12);
- }
- if (Q7.SelectedIndex == 3)
- {
- Int32 haha = d * spRice;
- price5.Text = Convert.ToString(haha * 1.12);
- }
- if (Q7.SelectedIndex == 4)
- {
- Int32 haha = E * spRice;
- price5.Text = Convert.ToString(haha * 1.12);
- }
- }
- private void button7_Click(object sender, EventArgs e)
- {
- if (Q7.SelectedItem == null)
- {
- MessageBox.Show("Please select an item", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(sprice1.Text, Q7.Text, reg5.Text, price5.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void size1_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (size1.SelectedIndex == 0)
- {
- price6.Text = Convert.ToString(filletrice * 1.12);
- sample.Text = Convert.ToString(filletrice);
- }
- if (size1.SelectedIndex == 1)
- {
- price6.Text = Convert.ToString(mediumfillet * 1.12);
- sample.Text = Convert.ToString(mediumfillet);
- }
- if (size1.SelectedIndex == 2)
- {
- price6.Text = Convert.ToString(largefillet * 1.12);
- sample.Text = Convert.ToString(largefillet);
- }
- }
- private void Q8_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (size1.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (Q8.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(sample.Text);
- price6.Text = Convert.ToString(haha * 1.12);
- }
- else if (Q8.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(sample.Text);
- price6.Text = Convert.ToString(haha * 1.12);
- }
- else if (Q8.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(sample.Text);
- price6.Text = Convert.ToString(haha * 1.12);
- }
- else if (Q8.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(sample.Text);
- price6.Text = Convert.ToString(haha * 1.12);
- }
- else if (Q8.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(sample.Text);
- price6.Text = Convert.ToString(haha * 1.12);
- }
- }
- private void sample_Click(object sender, EventArgs e)
- {
- }
- private void button8_Click(object sender, EventArgs e)
- {
- if (Q8.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (size1.SelectedItem == null)
- {
- MessageBox.Show("Please select a size first", "POS", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label30.Text, Q8.Text, size1.Text, price6.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void comboBox24_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox24.SelectedIndex == 0)
- {
- Int32 haha = a * mcsaverspaghetti;
- price7.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox24.SelectedIndex == 1)
- {
- Int32 haha = b * mcsaverspaghetti;
- price7.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox24.SelectedIndex == 2)
- {
- Int32 haha = c * mcsaverspaghetti;
- price7.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox24.SelectedIndex == 3)
- {
- Int32 haha = d * mcsaverspaghetti;
- price7.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox24.SelectedIndex == 4)
- {
- Int32 haha = E * mcsaverspaghetti;
- price7.Text = Convert.ToString(haha * 1.12);
- }
- }
- private void comboBox22_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox22.SelectedIndex == 0)
- {
- Int32 haha = a * chicsphag;
- price8.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox22.SelectedIndex == 1)
- {
- Int32 haha = b * chicsphag;
- price8.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox22.SelectedIndex == 2)
- {
- Int32 haha = c * chicsphag;
- price8.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox22.SelectedIndex == 3)
- {
- Int32 haha = d * chicsphag;
- price8.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox22.SelectedIndex == 4)
- {
- Int32 haha = E * chicsphag;
- price8.Text = Convert.ToString(haha * 1.12);
- }
- }
- private void comboBox20_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox20.SelectedIndex == 0)
- {
- Int32 haha = a * cmfries;
- price9.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox20.SelectedIndex == 1)
- {
- Int32 haha = b * cmfries;
- price9.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox20.SelectedIndex == 2)
- {
- Int32 haha = c * cmfries;
- price9.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox20.SelectedIndex == 3)
- {
- Int32 haha = d * cmfries;
- price9.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox20.SelectedIndex == 4)
- {
- Int32 haha = E * cmfries;
- price9.Text = Convert.ToString(haha * 1.12);
- }
- }
- private void comboBox18_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox18.SelectedIndex == 0)
- {
- Int32 haha = a * mcnuggets10;
- price10.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox18.SelectedIndex == 1)
- {
- Int32 haha = b * mcnuggets10;
- price10.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox18.SelectedIndex == 2)
- {
- Int32 haha = c * mcnuggets10;
- price10.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox18.SelectedIndex == 3)
- {
- Int32 haha = d * mcnuggets10;
- price10.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox18.SelectedIndex == 4)
- {
- Int32 haha = E * mcnuggets10;
- price10.Text = Convert.ToString(haha * 1.12);
- }
- }
- private void comboBox16_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox16.SelectedIndex == 0)
- {
- Int32 haha = a * chickmcdo2;
- price11.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox16.SelectedIndex == 1)
- {
- Int32 haha = b * chickmcdo2;
- price11.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox16.SelectedIndex == 2)
- {
- Int32 haha = c * chickmcdo2;
- price11.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox16.SelectedIndex == 3)
- {
- Int32 haha = d * chickmcdo2;
- price11.Text = Convert.ToString(haha * 1.12);
- }
- if (comboBox16.SelectedIndex == 4)
- {
- Int32 haha = E * chickmcdo2;
- price11.Text = Convert.ToString(haha * 1.12);
- }
- }
- private void button14_Click(object sender, EventArgs e)
- {
- if (comboBox24.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label58.Text, comboBox24.Text, reg1.Text, price7.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button13_Click(object sender, EventArgs e)
- {
- if (comboBox22.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(hm1.Text, comboBox22.Text, reg1.Text, price8.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button12_Click(object sender, EventArgs e)
- {
- if (comboBox20.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(hm2.Text, comboBox20.Text, reg1.Text, price9.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button11_Click(object sender, EventArgs e)
- {
- if (comboBox18.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(hm3.Text, comboBox18.Text, reg1.Text, price10.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button10_Click(object sender, EventArgs e)
- {
- if (comboBox16.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(hm4.Text, comboBox16.Text, reg1.Text, price11.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- total.Text = "0";
- ORNUMBER.Text = "0";
- amount.Text = "";
- change.Text = "0";
- discount1.Text = "0";
- }
- private void tabPage1_MouseEnter(object sender, EventArgs e)
- {
- double value = 0;
- for (int i = 0; i < listView1.Items.Count; i++)
- {
- if (listView1.Items.Count > 0)
- {
- value += double.Parse(listView1.Items[i].SubItems[3].Text);
- }
- }
- }
- private void comboBox47_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox47.SelectedIndex == 0)
- {
- cafe1.Text = Convert.ToString(mccafesmall);
- cafee1.Text = Convert.ToString(mccafesmall);
- }
- if (comboBox47.SelectedIndex == 1)
- {
- cafe1.Text = Convert.ToString(mccafemedium);
- cafee1.Text = Convert.ToString(mccafemedium);
- comboBox48.Text = "";
- cafe1.Text = "";
- }
- }
- private void comboBox48_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox48.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox47.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox48.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(cafee1.Text);
- cafe1.Text = Convert.ToString(haha);
- }
- else if (comboBox48.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(cafee1.Text);
- cafe1.Text = Convert.ToString(haha);
- }
- else if (comboBox48.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(cafee1.Text);
- cafe1.Text = Convert.ToString(haha);
- }
- else if (comboBox48.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(cafee1.Text);
- cafe1.Text = Convert.ToString(haha);
- }
- else if (comboBox48.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(cafee1.Text);
- cafe1.Text = Convert.ToString(haha);
- }
- }
- private void button20_Click(object sender, EventArgs e)
- {
- if (comboBox48.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox48.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox47.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label116.Text, comboBox48.Text, comboBox47.Text, cafe1.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void comboBox45_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox45.SelectedIndex == 0)
- {
- cafe2.Text = Convert.ToString(mccoffefloat);
- }
- }
- private void comboBox46_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox46.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox45.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox46.SelectedIndex == 0)
- {
- Int32 haha = a * mccoffefloat;
- cafe2.Text = Convert.ToString(haha);
- }
- else if (comboBox46.SelectedIndex == 1)
- {
- Int32 haha = b * mccoffefloat;
- cafe2.Text = Convert.ToString(haha);
- }
- else if (comboBox46.SelectedIndex == 2)
- {
- Int32 haha = c * mccoffefloat;
- cafe2.Text = Convert.ToString(haha);
- }
- else if (comboBox46.SelectedIndex == 3)
- {
- Int32 haha = d * mccoffefloat;
- cafe2.Text = Convert.ToString(haha);
- }
- else if (comboBox46.SelectedIndex == 4)
- {
- Int32 haha = E * mccoffefloat;
- cafe2.Text = Convert.ToString(haha);
- }
- }
- private void comboBox43_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox43.SelectedIndex == 0)
- {
- cafe3.Text = Convert.ToString(cokefloat);
- cafee3.Text = Convert.ToString(cokefloat);
- }
- if (comboBox43.SelectedIndex == 1)
- {
- cafe3.Text = Convert.ToString(cokefloatlarge);
- cafee3.Text = Convert.ToString(cokefloatlarge);
- }
- }
- private void comboBox44_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox44.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox43.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox44.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(cafee3.Text);
- cafe3.Text = Convert.ToString(haha);
- }
- else if (comboBox44.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(cafee3.Text);
- cafe3.Text = Convert.ToString(haha);
- }
- else if (comboBox44.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(cafee3.Text);
- cafe3.Text = Convert.ToString(haha);
- }
- else if (comboBox44.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(cafee3.Text);
- cafe3.Text = Convert.ToString(haha);
- }
- else if (comboBox44.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(cafee3.Text);
- cafe3.Text = Convert.ToString(haha);
- }
- }
- private void comboBox41_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox41.SelectedIndex == 0)
- {
- cafe4.Text = Convert.ToString(spritemedium);
- cafee4.Text = Convert.ToString(spritemedium);
- }
- if (comboBox41.SelectedIndex == 1)
- {
- cafe4.Text = Convert.ToString(spritelarge);
- cafee4.Text = Convert.ToString(spritelarge);
- }
- }
- private void comboBox42_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox42.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox41.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox42.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(cafee4.Text);
- cafe4.Text = Convert.ToString(haha);
- }
- else if (comboBox42.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(cafee4.Text);
- cafe4.Text = Convert.ToString(haha);
- }
- else if (comboBox42.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(cafee4.Text);
- cafe4.Text = Convert.ToString(haha);
- }
- else if (comboBox42.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(cafee4.Text);
- cafe4.Text = Convert.ToString(haha);
- }
- else if (comboBox42.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(cafee4.Text);
- cafe4.Text = Convert.ToString(haha);
- }
- }
- private void comboBox39_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox39.SelectedIndex == 0)
- {
- cafe5.Text = Convert.ToString(capuccinoS);
- cafee5.Text = Convert.ToString(capuccinoS);
- }
- if (comboBox39.SelectedIndex == 1)
- {
- cafe5.Text = Convert.ToString(capuccinoM);
- cafee5.Text = Convert.ToString(capuccinoM);
- }
- }
- private void tabPage4_Click(object sender, EventArgs e)
- {
- }
- private void comboBox40_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox40.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox39.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox40.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(cafee5.Text);
- cafe5.Text = Convert.ToString(haha);
- }
- else if (comboBox40.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(cafee5.Text);
- cafe5.Text = Convert.ToString(haha);
- }
- else if (comboBox40.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(cafee5.Text);
- cafe5.Text = Convert.ToString(haha);
- }
- else if (comboBox40.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(cafee5.Text);
- cafe5.Text = Convert.ToString(haha);
- }
- else if (comboBox40.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(cafee5.Text);
- cafe5.Text = Convert.ToString(haha);
- }
- }
- private void comboBox35_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox35.SelectedIndex == 0)
- {
- burger1.Text = Convert.ToString(bigmacM);
- burgerr1.Text = Convert.ToString(bigmacM);
- }
- if (comboBox35.SelectedIndex == 1)
- {
- burger1.Text = Convert.ToString(bigmacL);
- burgerr1.Text = Convert.ToString(bigmacL);
- }
- }
- private void comboBox36_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox36.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox35.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox36.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(burgerr1.Text);
- burger1.Text = Convert.ToString(haha);
- }
- else if (comboBox36.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(burgerr1.Text);
- burger1.Text = Convert.ToString(haha);
- }
- else if (comboBox36.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(burgerr1.Text);
- burger1.Text = Convert.ToString(haha);
- }
- else if (comboBox36.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(burgerr1.Text);
- burger1.Text = Convert.ToString(haha);
- }
- else if (comboBox36.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(burgerr1.Text);
- burger1.Text = Convert.ToString(haha);
- }
- }
- private void comboBox33_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox33.SelectedIndex == 0)
- {
- burger2.Text = Convert.ToString(mcspicyM);
- burgerr2.Text = Convert.ToString(mcspicyM);
- }
- if (comboBox33.SelectedIndex == 1)
- {
- burger2.Text = Convert.ToString(mcspicyL);
- burgerr2.Text = Convert.ToString(mcspicyL);
- }
- }
- private void comboBox34_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox34.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox33.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox34.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(burgerr2.Text);
- burger2.Text = Convert.ToString(haha);
- }
- else if (comboBox34.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(burgerr2.Text);
- burger2.Text = Convert.ToString(haha);
- }
- else if (comboBox34.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(burgerr2.Text);
- burger2.Text = Convert.ToString(haha);
- }
- else if (comboBox34.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(burgerr2.Text);
- burger2.Text = Convert.ToString(haha);
- }
- else if (comboBox34.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(burgerr2.Text);
- burger2.Text = Convert.ToString(haha);
- }
- }
- private void comboBox31_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox31.SelectedIndex == 0)
- {
- burger3.Text = Convert.ToString(bigntastyM);
- burgerr3.Text = Convert.ToString(bigntastyM);
- }
- if (comboBox31.SelectedIndex == 1)
- {
- burger3.Text = Convert.ToString(bigntastyL);
- burgerr3.Text = Convert.ToString(bigntastyL);
- }
- }
- private void comboBox32_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox32.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox31.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox32.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(burgerr3.Text);
- burger3.Text = Convert.ToString(haha);
- }
- else if (comboBox32.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(burgerr3.Text);
- burger3.Text = Convert.ToString(haha);
- }
- else if (comboBox32.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(burgerr3.Text);
- burger3.Text = Convert.ToString(haha);
- }
- else if (comboBox32.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(burgerr3.Text);
- burger3.Text = Convert.ToString(haha);
- }
- else if (comboBox32.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(burgerr3.Text);
- burger3.Text = Convert.ToString(haha);
- }
- }
- private void comboBox29_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox29.SelectedIndex == 0)
- {
- burger4.Text = Convert.ToString(cheeseburgerM);
- burgerr4.Text = Convert.ToString(cheeseburgerM);
- }
- if (comboBox29.SelectedIndex == 1)
- {
- burger4.Text = Convert.ToString(cheeseburgerL);
- burgerr4.Text = Convert.ToString(cheeseburgerL);
- }
- }
- private void comboBox30_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox30.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox29.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox30.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(burgerr4.Text);
- burger4.Text = Convert.ToString(haha);
- }
- else if (comboBox30.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(burgerr4.Text);
- burger4.Text = Convert.ToString(haha);
- }
- else if (comboBox30.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(burgerr4.Text);
- burger4.Text = Convert.ToString(haha);
- }
- else if (comboBox30.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(burgerr4.Text);
- burger4.Text = Convert.ToString(haha);
- }
- else if (comboBox30.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(burgerr4.Text);
- burger4.Text = Convert.ToString(haha);
- }
- }
- private void comboBox27_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox27.SelectedIndex == 0)
- {
- burger5.Text = Convert.ToString(burgerM);
- burgerr5.Text = Convert.ToString(burgerM);
- }
- if (comboBox27.SelectedIndex == 1)
- {
- burger5.Text = Convert.ToString(burgerL);
- burgerr5.Text = Convert.ToString(burgerL);
- }
- }
- private void comboBox28_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox28.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox27.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox28.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(burgerr5.Text);
- burger5.Text = Convert.ToString(haha);
- }
- else if (comboBox28.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(burgerr5.Text);
- burger5.Text = Convert.ToString(haha);
- }
- else if (comboBox28.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(burgerr5.Text);
- burger5.Text = Convert.ToString(haha);
- }
- else if (comboBox28.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(burgerr5.Text);
- burger5.Text = Convert.ToString(haha);
- }
- else if (comboBox28.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(burgerr5.Text);
- burger5.Text = Convert.ToString(haha);
- }
- }
- private void comboBox59_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox59.SelectedIndex == 0)
- {
- fries1.Text = Convert.ToString(friesR);
- friess1.Text = Convert.ToString(friesR);
- }
- if (comboBox59.SelectedIndex == 1)
- {
- fries1.Text = Convert.ToString(friesM);
- friess1.Text = Convert.ToString(friesM);
- }
- if (comboBox59.SelectedIndex == 2)
- {
- fries1.Text = Convert.ToString(friesL);
- friess1.Text = Convert.ToString(friesL);
- }
- }
- private void comboBox60_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox60.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox60.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(friess1.Text);
- fries1.Text = Convert.ToString(haha);
- }
- else if (comboBox60.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(friess1.Text);
- fries1.Text = Convert.ToString(haha);
- }
- else if (comboBox60.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(friess1.Text);
- fries1.Text = Convert.ToString(haha);
- }
- else if (comboBox60.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(friess1.Text);
- fries1.Text = Convert.ToString(haha);
- }
- else if (comboBox60.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(friess1.Text);
- fries1.Text = Convert.ToString(haha);
- }
- }
- private void comboBox57_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox57.SelectedIndex == 0)
- {
- fries2.Text = Convert.ToString(shakeR);
- friess2.Text = Convert.ToString(shakeR);
- }
- if (comboBox57.SelectedIndex == 1)
- {
- fries2.Text = Convert.ToString(shakeM);
- friess2.Text = Convert.ToString(shakeM);
- }
- if (comboBox57.SelectedIndex == 2)
- {
- fries2.Text = Convert.ToString(shakeR);
- friess2.Text = Convert.ToString(shakeR);
- }
- }
- private void comboBox58_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox58.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox58.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(friess2.Text);
- fries2.Text = Convert.ToString(haha);
- }
- else if (comboBox58.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(friess2.Text);
- fries2.Text = Convert.ToString(haha);
- }
- else if (comboBox58.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(friess2.Text);
- fries2.Text = Convert.ToString(haha);
- }
- else if (comboBox58.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(friess2.Text);
- fries2.Text = Convert.ToString(haha);
- }
- else if (comboBox58.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(friess2.Text);
- fries2.Text = Convert.ToString(haha);
- }
- }
- private void button9_Click(object sender, EventArgs e)
- {
- if (comboBox36.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox36.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox35.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label87.Text, comboBox36.Text, comboBox35.Text, burger1.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button19_Click(object sender, EventArgs e)
- {
- if (comboBox34.SelectedItem == null)
- {
- MessageBox.Show("Please complete the selection", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox34.SelectedItem == null)
- {
- MessageBox.Show("Please complete the selection", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox33.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label82.Text, comboBox34.Text, comboBox33.Text, burger2.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button18_Click(object sender, EventArgs e)
- {
- if (comboBox32.SelectedItem == null)
- {
- MessageBox.Show("Please comeplete the selection ", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox32.SelectedItem == null)
- {
- MessageBox.Show("Please comeplete the selection ", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox31.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label77.Text, comboBox32.Text, comboBox31.Text, burger3.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button17_Click(object sender, EventArgs e)
- {
- if (comboBox30.SelectedItem == null)
- {
- MessageBox.Show("Please comeplete the selection ", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox30.SelectedItem == null)
- {
- MessageBox.Show("Please comeplete the selection ", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox29.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label72.Text, comboBox30.Text, comboBox29.Text, burger4.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button16_Click(object sender, EventArgs e)
- {
- if (comboBox28.SelectedItem == null)
- {
- MessageBox.Show("Please comeplete the selection ", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox28.SelectedItem == null)
- {
- MessageBox.Show("Please comeplete the selection ", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox27.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label67.Text, comboBox28.Text, comboBox27.Text, burger5.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void rePrintReceiptToolStripMenuItem_Click(object sender, EventArgs e)
- {
- PRINT frm = new PRINT();
- frm.Show();
- this.Hide();
- }
- private void tabPage3_Click(object sender, EventArgs e)
- {
- }
- private void pictureBox3_Click(object sender, EventArgs e)
- {
- Q1.Show();
- }
- private void pictureBox4_Click(object sender, EventArgs e)
- {
- Q3.Show();
- }
- private void pictureBox5_Click(object sender, EventArgs e)
- {
- Q5.Show();
- }
- private void pictureBox19_Click(object sender, EventArgs e)
- {
- comboBox35.Visible = true;
- comboBox36.Visible = true;
- }
- private void pictureBox18_Click(object sender, EventArgs e)
- {
- comboBox33.Visible = true;
- comboBox34.Visible = true;
- }
- private void pictureBox17_Click(object sender, EventArgs e)
- {
- comboBox31.Visible = true;
- comboBox32.Visible = true;
- }
- private void pictureBox16_Click(object sender, EventArgs e)
- {
- comboBox29.Visible = true;
- comboBox30.Visible = true;
- }
- private void pictureBox15_Click(object sender, EventArgs e)
- {
- comboBox27.Visible = true;
- comboBox28.Visible = true;
- }
- private void pictureBox6_Click(object sender, EventArgs e)
- {
- Q7.Show();
- }
- private void pictureBox13_Click(object sender, EventArgs e)
- {
- comboBox24.Show();
- }
- private void pictureBox12_Click(object sender, EventArgs e)
- {
- comboBox22.Show();
- }
- private void pictureBox11_Click(object sender, EventArgs e)
- {
- comboBox20.Show();
- }
- private void pictureBox10_Click(object sender, EventArgs e)
- {
- comboBox18.Show();
- }
- private void pictureBox9_Click(object sender, EventArgs e)
- {
- comboBox16.Show();
- }
- private void button25_Click(object sender, EventArgs e)
- {
- if (comboBox46.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox46.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox45.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label111.Text, comboBox46.Text, comboBox45.Text, cafe2.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button24_Click(object sender, EventArgs e)
- {
- if (comboBox44.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox44.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox43.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label106.Text, comboBox44.Text, comboBox43.Text, cafe3.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button23_Click(object sender, EventArgs e)
- {
- if (comboBox42.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox42.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox41.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label101.Text, comboBox42.Text, comboBox41.Text, cafe4.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button22_Click(object sender, EventArgs e)
- {
- if (comboBox40.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox40.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox39.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label96.Text, comboBox40.Text, comboBox39.Text, cafe5.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void pictureBox25_Click(object sender, EventArgs e)
- {
- comboBox47.Visible = true;
- comboBox48.Visible = true;
- }
- private void pictureBox24_Click(object sender, EventArgs e)
- {
- comboBox45.Visible = true;
- comboBox46.Visible = true;
- }
- private void pictureBox23_Click(object sender, EventArgs e)
- {
- comboBox43.Visible = true;
- comboBox44.Visible = true;
- }
- private void pictureBox22_Click(object sender, EventArgs e)
- {
- comboBox41.Visible = true;
- comboBox42.Visible = true;
- }
- private void pictureBox21_Click(object sender, EventArgs e)
- {
- comboBox39.Visible = true;
- comboBox40.Visible = true;
- }
- private void comboBox55_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox55.SelectedIndex == 0)
- {
- fries3.Text = Convert.ToString(mcspicybundleM);
- friess3.Text = Convert.ToString(mcspicybundleM);
- }
- if (comboBox55.SelectedIndex == 1)
- {
- fries3.Text = Convert.ToString(mcspicybundleL);
- friess3.Text = Convert.ToString(mcspicybundleL);
- }
- }
- private void comboBox56_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox56.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox55.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox56.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(friess3.Text);
- fries3.Text = Convert.ToString(haha);
- }
- else if (comboBox56.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(friess3.Text);
- fries3.Text = Convert.ToString(haha);
- }
- else if (comboBox56.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(friess3.Text);
- fries3.Text = Convert.ToString(haha);
- }
- else if (comboBox56.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(friess3.Text);
- fries3.Text = Convert.ToString(haha);
- }
- else if (comboBox56.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(friess3.Text);
- fries3.Text = Convert.ToString(haha);
- }
- }
- private void comboBox53_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox53.SelectedIndex == 0)
- {
- fries4.Text = Convert.ToString(bigntastybundleM);
- friess4.Text = Convert.ToString(bigntastybundleM);
- }
- if (comboBox53.SelectedIndex == 1)
- {
- fries4.Text = Convert.ToString(bigntastybundleL);
- friess4.Text = Convert.ToString(bigntastybundleL);
- }
- }
- private void comboBox54_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox54.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox53.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox54.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(friess4.Text);
- fries4.Text = Convert.ToString(haha);
- }
- else if (comboBox54.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(friess4.Text);
- fries4.Text = Convert.ToString(haha);
- }
- else if (comboBox54.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(friess4.Text);
- fries4.Text = Convert.ToString(haha);
- }
- else if (comboBox54.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(friess4.Text);
- fries4.Text = Convert.ToString(haha);
- }
- else if (comboBox54.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(friess4.Text);
- fries4.Text = Convert.ToString(haha);
- }
- }
- private void comboBox51_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox51.SelectedIndex == 0)
- {
- fries5.Text = Convert.ToString(bigmcbundleM);
- friess5.Text = Convert.ToString(bigmcbundleM);
- }
- if (comboBox51.SelectedIndex == 1)
- {
- fries5.Text = Convert.ToString(bigmcbundleL);
- fries5.Text = Convert.ToString(bigmcbundleL);
- }
- }
- private void tabPage5_Click(object sender, EventArgs e)
- {
- }
- private void comboBox52_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox52.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox51.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox52.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(friess5.Text);
- fries5.Text = Convert.ToString(haha);
- }
- else if (comboBox52.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(friess5.Text);
- fries5.Text = Convert.ToString(haha);
- }
- else if (comboBox52.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(friess5.Text);
- fries5.Text = Convert.ToString(haha);
- }
- else if (comboBox52.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(friess5.Text);
- fries5.Text = Convert.ToString(haha);
- }
- else if (comboBox52.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(friess5.Text);
- fries5.Text = Convert.ToString(haha);
- }
- }
- private void comboBox49_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox49.SelectedIndex == 0)
- {
- label23.Text = Convert.ToString(applepie);
- applepiee.Text = Convert.ToString(applepie);
- }
- }
- private void comboBox50_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (comboBox50.SelectedItem == null)
- {
- MessageBox.Show("Please select a Quantity", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox49.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox50.SelectedIndex == 0)
- {
- Int32 haha = a * Convert.ToInt32(applepiee.Text);
- label23.Text = Convert.ToString(haha);
- }
- else if (comboBox50.SelectedIndex == 1)
- {
- Int32 haha = b * Convert.ToInt32(applepiee.Text);
- label23.Text = Convert.ToString(haha);
- }
- else if (comboBox50.SelectedIndex == 2)
- {
- Int32 haha = c * Convert.ToInt32(applepiee.Text);
- label23.Text = Convert.ToString(haha);
- }
- else if (comboBox50.SelectedIndex == 3)
- {
- Int32 haha = d * Convert.ToInt32(applepiee.Text);
- label23.Text = Convert.ToString(haha);
- }
- else if (comboBox52.SelectedIndex == 4)
- {
- Int32 haha = E * Convert.ToInt32(friess5.Text);
- fries5.Text = Convert.ToString(haha);
- }
- }
- private void button32_Click(object sender, EventArgs e)
- {
- if (comboBox60.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox60.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox59.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label145.Text, comboBox60.Text, comboBox59.Text, fries1.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button31_Click(object sender, EventArgs e)
- {
- if (comboBox58.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox58.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox57.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label140.Text, comboBox58.Text, comboBox57.Text, fries2.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button30_Click(object sender, EventArgs e)
- {
- if (comboBox56.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox56.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox55.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label135.Text, comboBox56.Text, comboBox55.Text, fries3.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button29_Click(object sender, EventArgs e)
- {
- if (comboBox54.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox54.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox53.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label130.Text, comboBox54.Text, comboBox53.Text, fries4.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button28_Click(object sender, EventArgs e)
- {
- if (comboBox52.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox52.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox51.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label125.Text, comboBox52.Text, comboBox51.Text, fries5.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button27_Click(object sender, EventArgs e)
- {
- if (comboBox50.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox50.SelectedItem == null)
- {
- MessageBox.Show("Please select a quantity", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else if (comboBox49.SelectedItem == null)
- {
- MessageBox.Show("Please select a size", "Orders", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(label124.Text, comboBox50.Text, comboBox49.Text, label23.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void refreshFormToolStripMenuItem_Click(object sender, EventArgs e)
- {
- this.Close();
- pane frm = new pane();
- frm.Show();
- }
- private void pictureBox31_Click(object sender, EventArgs e)
- {
- comboBox59.Visible = true;
- comboBox60.Visible = true;
- }
- private void pictureBox30_Click(object sender, EventArgs e)
- {
- comboBox57.Visible = true;
- comboBox58.Visible = true;
- }
- private void pictureBox29_Click(object sender, EventArgs e)
- {
- comboBox55.Visible = true;
- comboBox56.Visible = true;
- }
- private void pictureBox28_Click(object sender, EventArgs e)
- {
- comboBox53.Visible = true;
- comboBox54.Visible = true;
- }
- private void pictureBox27_Click(object sender, EventArgs e)
- {
- comboBox51.Visible = true;
- comboBox52.Visible = true;
- }
- private void pictureBox26_Click(object sender, EventArgs e)
- {
- comboBox49.Visible = true;
- comboBox50.Visible = true;
- }
- private void button21_Click(object sender, EventArgs e)
- {
- if (total.Text == "0")
- {
- MessageBox.Show("Get the total first.");
- }
- else if (total.Text == "0")
- {
- MessageBox.Show("Get the total first.");
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Does the customer has a proof that he/she's a senior?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- Double haha = Convert.ToDouble(discounttext.Text) * dc;
- total.Text = Convert.ToString(haha);
- discount1.Text = "5%";
- MessageBox.Show("Discount added successfully", "POS", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void listView1_Click(object sender, EventArgs e)
- {
- double value = 0;
- for (int i = 0; i < listView1.Items.Count; i++)
- {
- value += double.Parse(listView1.Items[i].SubItems[3].Text);
- }
- total.Text = Convert.ToString(value);
- discounttext.Text = Convert.ToString(value);
- }
- private void bestseller_MouseEnter(object sender, EventArgs e)
- {
- bestseller.TabStop = false;
- bestseller.FlatStyle = FlatStyle.Flat;
- bestseller.BackColor = Color.FromArgb(178, 15, 25);
- bestseller.FlatAppearance.BorderColor = Color.FromArgb(178, 15, 25);
- }
- private void bestseller_MouseLeave(object sender, EventArgs e)
- {
- bestseller.TabStop = false;
- bestseller.FlatStyle = FlatStyle.Flat;
- bestseller.BackColor = Color.DarkRed;
- bestseller.FlatAppearance.BorderColor = Color.DarkRed;
- }
- private void button15_Click(object sender, EventArgs e)
- {
- food.Text = "Egg Muffin Ala Carte";
- label2.Text = Convert.ToString(mcmuffinA);
- php1.Text = Convert.ToString(mcmuffinA);
- numericUpDown1.Value = 1;
- numericUpDown1.Enabled = true;
- }
- private void button26_Click(object sender, EventArgs e)
- {
- food.Text = "Egg Muffin Meal";
- label2.Text = Convert.ToString(mcmuffinmeal);
- php2.Text = Convert.ToString(mcmuffinmeal);
- numericUpDown1.Value = 1;
- numericUpDown1.Enabled = true;
- }
- private void button33_Click(object sender, EventArgs e)
- {
- food.Text = "Eggmuffin with Hashbrown";
- label2.Text = Convert.ToString(mcmuffinL);
- php3.Text = Convert.ToString(mcmuffinL);
- numericUpDown1.Value = 1;
- numericUpDown1.Enabled = true;
- }
- private void bestseller_Click(object sender, EventArgs e)
- {
- tabControl1.SelectTab(5);
- }
- private void numericUpDown1_ValueChanged(object sender, EventArgs e)
- {
- if (food.Text == "Egg Muffin Ala Carte")
- {
- Int32 haha = Convert.ToInt32(php1.Text) * Convert.ToInt32(numericUpDown1.Value);
- label2.Text = Convert.ToString(haha);
- }
- if (food.Text == "Egg Muffin Meal")
- {
- Int32 haha = Convert.ToInt32(php2.Text) * Convert.ToInt32(numericUpDown1.Value);
- label2.Text = Convert.ToString(haha);
- }
- if (food.Text == "Eggmuffin with Hashbrown")
- {
- Int32 haha = Convert.ToInt32(php3.Text) * Convert.ToInt32(numericUpDown1.Value);
- label2.Text = Convert.ToString(haha);
- }
- }
- private void button39_Click(object sender, EventArgs e)
- {
- f1.Text = "Fries Medium";
- label14.Text = Convert.ToString(friesM);
- f4.Text = Convert.ToString(friesM);
- numericUpDown2.Value = 1;
- numericUpDown2.Enabled = true;
- }
- private void button38_Click_1(object sender, EventArgs e)
- {
- f1.Text = "Fries Regular";
- label14.Text = Convert.ToString(friesR);
- f5.Text = Convert.ToString(friesR);
- numericUpDown2.Value = 1;
- numericUpDown2.Enabled = true;
- }
- private void button36_Click_1(object sender, EventArgs e)
- {
- f1.Text = "Fries Large";
- label14.Text = Convert.ToString(friesL);
- f6.Text = Convert.ToString(friesL);
- numericUpDown2.Value = 1;
- numericUpDown2.Enabled = true;
- }
- private void numericUpDown2_ValueChanged(object sender, EventArgs e)
- {
- if (f1.Text == "Fries Medium")
- {
- Int32 haha = Convert.ToInt32(f4.Text) * Convert.ToInt32(numericUpDown2.Value);
- label14.Text = Convert.ToString(haha);
- }
- if (f1.Text == "Fries Regular")
- {
- Int32 haha = Convert.ToInt32(f5.Text) * Convert.ToInt32(numericUpDown2.Value);
- label14.Text = Convert.ToString(haha);
- }
- if (f1.Text == "Fries Large")
- {
- Int32 haha = Convert.ToInt32(f6.Text) * Convert.ToInt32(numericUpDown2.Value);
- label14.Text = Convert.ToString(haha);
- }
- }
- private void button34_Click_1(object sender, EventArgs e)
- {
- if (numericUpDown1.Value == 0)
- {
- MessageBox.Show("Please select from choices first and add a quantity.", "POS", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else if (numericUpDown1.Value == 0)
- {
- MessageBox.Show("Please select from choices and add a quantity.", "POS", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else if (label2.Text == "")
- {
- MessageBox.Show("Complete the requirements first", "[POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(bes1.Text, numericUpDown1.Text, reg2.Text, label2.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void button35_Click_1(object sender, EventArgs e)
- {
- if (numericUpDown2.Value == 0)
- {
- MessageBox.Show("Please select from choices first and add a quantity.", "POS", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else if (numericUpDown2.Value == 0)
- {
- MessageBox.Show("Please select from choices and add a quantity.", "POS", MessageBoxButtons.OK, MessageBoxIcon.Information);
- }
- else if (label14.Text == "")
- {
- MessageBox.Show("Complete the requirements first", "[POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
- }
- else
- {
- DialogResult dialogResult = MessageBox.Show("Orders will now add to cart?", "Orders", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- add(bes2.Text, numericUpDown2.Text, f1.Text, label14.Text);
- }
- else if (dialogResult == DialogResult.No)
- {
- }
- }
- }
- private void listView1_SelectedIndexChanged(object sender, EventArgs e)
- {
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement