Ejemplo n.º 1
0
 //On login Click, checks if the emplyee username and password are in the DB
 private void button2_Click(object sender, EventArgs e)
 {
     Get_Data();
     DataRow[] dr = ds.Employees.Select();
     foreach (DataRow d in dr)
     {
         if (d[2].ToString() == textBox4.Text && d[3].ToString() == textBox5.Text)
         {
             employeeId   = d[0].ToString();
             this.Visible = false;
             panel6.Hide();
             if (!tableFormInit)
             {
                 tablesForm = new Tables(this);
                 tablesForm.Show(this);
                 tableFormInit = true;
             }
             else
             {
                 tablesForm.Show(this);
             }
             return;
         }
     }
     MessageBox.Show("Invalid Username/Password combination");
 }
Ejemplo n.º 2
0
 private void tableToolStripMenuItem_Click(object sender, EventArgs e)
 {
     tableForm.Show();
     this.Close();
 }