Пример #1
0
        private void AddUserBtn_Click(object sender, EventArgs e)
        {
            addUserForm1 = new addUserForm();

            /*string name = listView1.SelectedItems[0].SubItems[0].Text;
             * string surname = listView1.SelectedItems[0].SubItems[1].Text;
             * string SecName = listView1.SelectedItems[0].SubItems[2].Text;
             * string pos = listView1.SelectedItems[0].SubItems[3].Text;
             * addUserForm1.init(name, surname, SecName, pos);*/
            UserOk           = addUserForm1;
            addUserForm1.OK += AddUserForm1_OK;
            //addUserForm1.Change += AddUserForm1_Change;
            addUserForm1.Show();
        }
Пример #2
0
        private void ChangeBtn_Click(object sender, EventArgs e)
        {
            addUserForm1 = new addUserForm();
            string name    = listView1.SelectedItems[0].SubItems[0].Text;
            string surname = listView1.SelectedItems[0].SubItems[1].Text;
            string SecName = listView1.SelectedItems[0].SubItems[2].Text;
            string pos     = listView1.SelectedItems[0].SubItems[3].Text;
            string id      = listView1.SelectedItems[0].SubItems[4].Text;

            addUserForm1.init(name, surname, SecName, pos, id);
            addUserForm1.OK += AddUserForm1_OK1;
            //addUserForm1.Change += AddUserForm1_Change;
            //addUserForm1.StName.Text;
            addUserForm1.Show();
        }