예제 #1
0
        private void btnNew_Click(object sender, EventArgs e)
        {
            frmAddEdit frm = new frmAddEdit();

            frm.Text = "Add";
            frm.Show();
            this.Hide();
        }
예제 #2
0
        public void btnUpdate_Click(object sender, EventArgs e)
        {
            frmAddEdit frm = new frmAddEdit(
                dataGridView1.CurrentRow.Cells[0].Value.ToString(),
                dataGridView1.CurrentRow.Cells[1].Value.ToString(),
                dataGridView1.CurrentRow.Cells[2].Value.ToString(),
                dataGridView1.CurrentRow.Cells[3].Value.ToString(),
                dataGridView1.CurrentRow.Cells[4].Value.ToString()
                );

            frm.Text = "Update";
            frm.Show();
            this.Hide();
        }