예제 #1
0
 private void btnAdd_Click(object sender, EventArgs e)
 {
     if (!loggedUser.access(Convert.ToInt16(btnAdd.Tag)))
     {
         return;
     }
     MealAdd add = new MealAdd(loggedUser);
     add.ShowDialog();
     LoadMeals();
 }
예제 #2
0
        private void addToolStripMenuItem2_Click(object sender, EventArgs e)
        {
            if (!loggedIn())
            {
                return;
            }
            if (!loggedUser.access(Convert.ToInt16(addToolStripMenuItem2.Tag)))
            {
                return;
            }

            MealAdd add = new MealAdd(loggedUser);

            add.ShowDialog();
        }