Esempio n. 1
0
        private void suatoolStripButton1_Click(object sender, EventArgs e)
        {
            DialogResult dalRs;

            if (tabControl1.SelectedTab == vBDebtabPage)
            {
                VBDen vbden = new VBDen(true, vBDendataGridView.SelectedRows[0].Cells);
                dalRs = vbden.ShowDialog(this);
                if (dalRs == DialogResult.OK)
                {
                    loadTreeView(vbdenDate, vbDentreeView);
                }
            }
            else if (tabControl1.SelectedTab == vBDitabPage)
            {
                VBDi vbdi = new VBDi(true, vBDidataGridView.SelectedRows[0].Cells);
                dalRs = vbdi.ShowDialog(this);
                if (dalRs == DialogResult.OK)
                {
                    loadTreeView(vbdiDate, vBDitreeView);
                }
            }
            else if (tabControl1.SelectedTab == kQTKtabPage)
            {
                if (ketQuaLoaiVB == 1)
                {
                    VBDen vbden = new VBDen(true, kQTKdataGridView.SelectedRows[0].Cells);
                    if (vbden.ShowDialog(this) == DialogResult.OK)
                    {
                        loadTreeView(vbdenDate, vbDentreeView);
                        tabControl1.SelectedTab = vBDebtabPage;
                    }
                }
                else
                {
                    VBDi vbdi = new VBDi(true, kQTKdataGridView.SelectedRows[0].Cells);
                    if (vbdi.ShowDialog(this) == DialogResult.OK)
                    {
                        loadTreeView(vbdiDate, vBDitreeView);
                        tabControl1.SelectedTab = vBDitabPage;
                    }
                }
                dataSetKQ.Clear();
            }
        }
Esempio n. 2
0
        private void themtoolStripButton_Click(object sender, EventArgs e)
        {
            DialogResult dalRs;

            if (tabControl1.SelectedTab == vBDebtabPage)
            {
                VBDen vbden = new VBDen(false, null);
                dalRs = vbden.ShowDialog(this);
                if (dalRs == DialogResult.OK)
                {
                    loadTreeView(vbdenDate, vbDentreeView);
                }
            }
            else if (tabControl1.SelectedTab == vBDitabPage)
            {
                VBDi vbdi = new VBDi(false, null);
                dalRs = vbdi.ShowDialog(this);
                if (dalRs == DialogResult.OK)
                {
                    loadTreeView(vbdiDate, vBDitreeView);
                }
            }
        }