Example #1
0
        private void button8_Click(object sender, EventArgs e)
        {
            // pridat kredit uložiť button
            string          login     = pridatKredit_login.Text;
            string          balance   = pridatKredit_kredity.Text;
            List <Customer> customers = Customer.ShowCustomersLogin(login);

            foreach (Customer c in customers)
            {
                listBox3.Items.Clear();
            }

            Customer.Update_balance(balance, login);

            List <Customer> customers2 = Customer.ShowCustomersLogin(login);

            foreach (Customer c in customers2)
            {
                listBox3.Items.Add(c.login);
                listBox3.Items.Add(c.balance);
                listBox3.Items.Add("________________________________________");
            }
        }