Пример #1
0
        private void btnMake_Click(object sender, EventArgs e)
        {
            if(txtPass.Text==txtPassConf.Text)
            {
                Accounts a = new Accounts(txtUser.Text, txtPass.Text, Int32.Parse(txtPhone.Text));
                list.listAccounts.Add(a);
                //traverse list to get index of new account
                for (int i =0;i<list.listAccounts.Count;i++)
                {
                    if (list.listAccounts[i].getUser() == a.getUser())
                    {
                        list.accountIndex = i;
                    }
                }

                this.Hide();
                frmMainMenu f2 = new frmMainMenu();
                f2.Show();

            }

        }
Пример #2
0
 //display home page
 private void button1_Click(object sender, EventArgs e)
 {
     frmMainMenu f = new frmMainMenu();
     this.Hide();
     f.Show();
 }