Ejemplo n.º 1
0
 public Buyinvoices()
 {
     InitializeComponent();
     lgic = new logic();
     ds   = lgic.get_tabl("perchas");
     sal_gridview.DataSource = ds.Tables[0];
     count(ds);
     sal_ad_name.DataSource       = lgic.combodata("perchas", "saller_name");
     sal_srch_sal_name.DataSource = lgic.combodata("perchas", "saller_name");
 }
Ejemplo n.º 2
0
 public Invoices()
 {
     InitializeComponent();
     lgic = new logic();
     ds   = lgic.get_tabl("invoice");
     invn_gridview.DataSource = ds.Tables[0];
     count(ds);
     invn_ad_cst_name.DataSource   = lgic.combodata("invoice", "customer_name");
     invn_srch_cst_name.DataSource = lgic.combodata("invoice", "customer_name");
 }
Ejemplo n.º 3
0
        private void sal_ad_done_Click(object sender, EventArgs e)
        {
            sal_ad_name.Select();
            string[] at = { sal_ad_name.Text,   sal_ad_invoicenmbr.Text, sal_ad_detail.Text,
                            sal_ad_total.Text,  sal_ad_pay.Text,         sal_ad_balance.Text,
                            sal_ad_status.Text, sal_datetoday.Value.ToString() };
            string   msg = lgic.invoicesale(at);

            MessageBox.Show(msg);


            ds = lgic.get_tabl("perchas");
            sal_gridview.DataSource = ds.Tables[0];
            count(ds);

            sal_srch_sal_name.DataSource = lgic.combodata("perchas", "saller_name");
            int index = sal_srch_sal_name.FindString(sal_ad_name.Text);

            sal_srch_sal_name.SelectedIndex = index;

            sal_ad_name.Text        = "";
            sal_ad_invoicenmbr.Text = "";
            sal_ad_detail.Text      = "";
            sal_ad_total.Text       = "0";
            sal_ad_pay.Text         = "0";
            sal_ad_balance.Text     = "0";
            sal_ad_name.Select();
        }
Ejemplo n.º 4
0
        private void button4_Click(object sender, EventArgs e)  //done button
        {
            // here write function that save data

            string[] at = { invn_ad_cst_name.Text, invn_ad_invoicenmbr.Text, inv1_ad_detail.Text,
                            invn_ad_total.Text,    invn_ad_receive.Text,     invn_ad_balance.Text,
                            invn_ad_status.Text,   inv_datetoday.Value.ToString() };
            string   msg = lgic.invoicedata(at);

            MessageBox.Show(msg);

            ds = lgic.get_tabl("invoice");
            invn_gridview.DataSource = ds.Tables[0];
            count(ds);

            invn_srch_cst_name.DataSource = lgic.combodata("invoice", "customer_name");
            int index = invn_srch_cst_name.FindString(invn_ad_cst_name.Text);

            invn_srch_cst_name.SelectedIndex = index;

            inv1_ad_detail.Text      = "";
            invn_ad_invoicenmbr.Text = "";
            invn_ad_receive.Text     = "";
            invn_ad_total.Text       = "";
            invn_ad_balance.Text     = "";
            invn_ad_cst_name.Select();
        }