private void registrationToolStripMenuItem2_Click_1(object sender, EventArgs e)
        {
            this.Hide();
            frmUserRegistrations frm = new frmUserRegistrations();

            frm.lblUserType.Text = UserType.Text;
            frm.lblUser.Text     = User.Text;
            frm.Show();
        }
Esempio n. 2
0
        private void frmRegisteredUsersDetails_FormClosing(object sender, FormClosingEventArgs e)
        {
            this.Hide();
            frmUserRegistrations frm = new frmUserRegistrations();

            frm.lblUserType.Text = lblUserType.Text;
            frm.lblUser.Text     = lblUser.Text;
            frm.Show();
        }
Esempio n. 3
0
        private void dataGridView1_RowHeaderMouseClick(object sender, DataGridViewCellMouseEventArgs e)
        {
            DataGridViewRow dr = dataGridView1.SelectedRows[0];

            this.Hide();
            frmUserRegistrations frm = new frmUserRegistrations();

            // or simply use column name instead of index
            //dr.Cells["id"].Value.ToString();
            frm.Show();
            frm.UserID.Text              = dr.Cells[0].Value.ToString();
            frm.TextBox1.Text            = dr.Cells[0].Value.ToString();
            frm.txtPassword.Text         = dr.Cells[1].Value.ToString();
            frm.txtName.Text             = dr.Cells[2].Value.ToString();
            frm.txtContact_no.Text       = dr.Cells[3].Value.ToString();
            frm.txtEmail_Address.Text    = dr.Cells[4].Value.ToString();
            frm.cmbUsertype.Text         = dr.Cells[5].Value.ToString();
            frm.lblUser.Text             = lblUser.Text;
            frm.lblUserType.Text         = lblUserType.Text;
            frm.btnDelete.Enabled        = true;
            frm.btnUpdate_record.Enabled = true;
            frm.btnRegister.Enabled      = false;
            frm.UserID.Focus();
        }