Exemplo n.º 1
0
        private void UcNVdetail_Load(object sender, EventArgs e)
        {
            _obj           = this;
            hoso.BackColor = Color.DodgerBlue;

            Profile pr = new Profile(this.manv);

            pr.Dock = DockStyle.Fill;
            pContainer1.Controls.Add(pr);
        }
Exemplo n.º 2
0
        private void dataGridView1_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            string str = null;

            if (e.RowIndex >= 0)
            {
                if (dataGridView1.Rows[e.RowIndex].Cells["MaNV"].Value.ToString() != "")
                {
                    str = dataGridView1.Rows[e.RowIndex].Cells["MaNV"].Value.ToString();

                    if (!home.Instance.PanelContainer.Controls.ContainsKey("UcNVdetail"))
                    {
                        UcNVdetail ucnv = new UcNVdetail(str);
                        ucnv.Dock = DockStyle.Fill;
                        home.Instance.PanelContainer.Controls.Add(ucnv);
                    }
                    home.Instance.PanelContainer.Controls["UcNVdetail"].BringToFront();
                }
                else
                {
                    MessageBox.Show("Cần chọn hàng có thông tin", "Thông Báo", MessageBoxButtons.OK, MessageBoxIcon.Information);
                }
            }
        }