コード例 #1
0
        private void btnAddUser_Click(object sender, EventArgs e)
        {
            AddUser_Form ob = new AddUser_Form();

            ob.ShowDialog();
            dataGridView1.DataSource = BL.Users.GetUsers();
        }
コード例 #2
0
        private void btnModify_Click(object sender, EventArgs e)
        {
            AddUser_Form ob = new AddUser_Form();

            ob.txtID.Text      = dataGridView1.CurrentRow.Cells[0].Value.ToString();
            ob.txtPass.Text    = dataGridView1.CurrentRow.Cells[1].Value.ToString();
            ob.txtPassCon.Text = dataGridView1.CurrentRow.Cells[1].Value.ToString();
            ob.comboBox1.Text  = dataGridView1.CurrentRow.Cells[2].Value.ToString();
            ob.btnAdd.Text     = "Modify";
            ob.txtID.ReadOnly  = true;
            ob.ShowDialog();
            dataGridView1.DataSource = BL.Users.GetUsers();
        }
コード例 #3
0
        private void addUserToolStripMenuItem_Click(object sender, EventArgs e)
        {
            AddUser_Form ob = new AddUser_Form();

            ob.ShowDialog();
        }