示例#1
0
        private void button1_Click(object sender, EventArgs e)
        {
            int DebtSaleNo = 1;

            for (int i = 0; i < dataGridView1.Rows.Count - 1; i++)
            {
                DebitSale.setDSale(Convert.ToInt32(addCustomer.Text), i, Convert.ToInt32(dataGridView1.Rows[i].Cells["Product No"].Value), Convert.ToSingle(dataGridView1.Rows[i].Cells["Unit Input Price"].Value), DateTime.Now, "Cari", "aa", Convert.ToInt32(dataGridView1.Rows[i].Cells["Barcode No"].Value), Convert.ToSingle(dataGridView1.Rows[i].Cells["Sale Price"].Value));
                //CustomerDebt.setCDebt(Convert.ToInt32(addCustomer.Text), Convert.ToInt32(dataGridView1.Rows[i].Cells["Unit Input Price"].Value) * Convert.ToInt32(dataGridView1.Rows[i].Cells["Amount"].Value), DateTime.Now, i);
            }
            //CustomerDebt.setCDebt(Convert.ToInt32(addCustomer.Text), Convert.ToInt32(label5.Text), DateTime.Now, DebitSale.getDebitSale(Convert.ToInt32( addCustomer.Text)).sale_no );
            MessageBox.Show("THE SALE WAS MADE ");
            DebtSaleNo++;
            label5.Text      = "0 ₺";
            addCustomer.Text = "";
            table.Clear();
        }