Beispiel #1
0
        private void Sell_Load(object sender, EventArgs e)
        {
            Mainmenu = Application.OpenForms["MainMenu"];

            foreach (Product item in ((MainMenu)Mainmenu).GetProduct())
            {
                ListViewItem li = new ListViewItem();
                li.Text = item.ProductName;
                li.SubItems.Add(item.UnitPrice.ToString());
                lstSell.Items.Add(li);
            }

            txtPrice.Text = orepo.CalculatePrice(((MainMenu)Mainmenu).GetProduct()).ToString();
        }