Example #1
0
        private void Open_Customer_Load(object sender, EventArgs e)
        {
            con.Open();
            dataGridView1.Rows.Clear();
            Dt             = new DataTable();
            com            = new SqlCommand("select company_name,contact_person,phone_puplic,sales_person,custmer_group,blance from customer");
            com.Connection = con;
            adapt          = new SqlDataAdapter(com);
            adapt.Fill(Dt);

            // dataGridView1.DataSource = Dt;

            for (int i = 0; i < Dt.Rows.Count; i++)
            {
                dataGridView1.Rows.Add(Dt.Rows[i][0], Dt.Rows[i][1], Dt.Rows[i][2], Dt.Rows[i][3], Dt.Rows[i][4], Dt.Rows[i][5]);
            }
            con.Close();


            ado_project f = new ado_project();

            dt = f.combo_opencust();

            dr    = dt.NewRow();
            dr[0] = "All";
            dt.Rows.Add(dr);

            comboBox1.DataSource    = dt;
            comboBox1.DisplayMember = dt.Columns[0].ToString();

            Open_Customer op = new Open_Customer();

            op.Refresh();
        }
Example #2
0
        private void button1_Click(object sender, EventArgs e)
        {
            Open_Customer oc = new Open_Customer();

            oc.ShowDialog();
        }
Example #3
0
        private void openCustomerToolStripMenuItem_Click(object sender, EventArgs e)
        {
            Open_Customer op = new Open_Customer();

            op.ShowDialog();
        }
Example #4
0
        private void allCompanyToolStripMenuItem_Click(object sender, EventArgs e)
        {
            Open_Customer c = new Open_Customer();

            c.ShowDialog();
        }