private void btnSeeAllEntry_Click(object sender, EventArgs e)
        {
            FormShop.CurrentUser = EntryControl.CurrentUser;
            FormShop formShop = new FormShop(this);

            formShop.ShowDialog();
        }
Exemple #2
0
        private void btJoinUser_Click(object sender, EventArgs e)
        {
            MySqlConnection conectaruser = new MySqlConnection("server=localhost; database=login; UID=root; password=;");

            conectaruser.Open();

            MySqlCommand    codigo     = new MySqlCommand();
            MySqlConnection conectanos = new MySqlConnection();

            codigo.Connection = conectaruser;

            codigo.CommandText = ("Select *from logindatos where nombre ='" + tbNickUser.Text + "'and contraseña = '" + tbPassUser.Text + "'");

            MySqlDataReader leer = codigo.ExecuteReader();

            if (leer.Read())
            {
                MessageBox.Show("bienvenido");
                Form register = new FormShop();
                register.Show();
                this.Hide();
            }
            else
            {
                MessageBox.Show("error");
            }
            conectaruser.Close();
        }
Exemple #3
0
 private void LojasToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (FSh != null)
     {
         FSh.Close();
     }
     FSh = new FormShop {
         MdiParent = this
     };
     FSh.Activate();
     FSh.Show();
 }