Beispiel #1
0
        private void button7_Click(object sender, EventArgs e)
        {
            FinalForm ff = new FinalForm();

            ff.Show();
            this.Show();
        }
Beispiel #2
0
        private void button10_Click(object sender, EventArgs e)
        {
            FinalForm s = new FinalForm();

            s.Show();
            this.Hide();
        }
Beispiel #3
0
        private void returnBtn_Click(object sender, EventArgs e)
        {
            FinalForm ff = new FinalForm();

            ff.Show();
            this.Hide();
        }
Beispiel #4
0
        private void button1_Click(object sender, EventArgs e)
        {
            errorMsg.Text = "";
            if (LoginUserTableAdapter.checkLogin(loginUserTxtBox.Text, loginPassTxtBox.Text).Value == 1)
            {
                UserClass.firstTime = true;
                UserClass.Name      = loginUserTxtBox.Text;
                UserClass.Password  = loginPassTxtBox.Text;
                int n = int.Parse(LoginUserTableAdapter.GetFindUser(UserClass.Name, UserClass.Password).Rows[0][0].ToString());

                if (int.Parse(LoginUserTableAdapter.GetCheckForUpdated(UserClass.Name, UserClass.Password).Rows[0]["BMI"].ToString()) != 0)
                {
                    if (goalsTableAdapter1.getGoalsAndStatus(n, "Incomplete") < 1)
                    {
                        TrainningForm tf = new TrainningForm();
                        tf.Show();
                        this.Hide();
                    }
                    else if (userRoutineTableAdapter1.checkRoutine(n) < 1)
                    {
                        RoutineMenu rm = new RoutineMenu();
                        rm.Show();
                        this.Hide();
                    }
                    else if (userDietPlanTableAdapter1.checkDietPlan(n) < 1)
                    {
                        DietForm df = new DietForm();
                        df.Show();
                        this.Hide();
                    }
                    else
                    {
                        FinalForm ff = new FinalForm();
                        UserClass.firstTime = false;
                        ff.Show();
                        this.Hide();
                    }
                }
                else
                {
                    PersonalData pd = new PersonalData();
                    pd.Show();
                    this.Hide();
                }
            }
            else
            {
                errorMsg.Text = "Wrong Username or Password. \nPlease try again!";
            }
        }
Beispiel #5
0
        private void button2_Click(object sender, EventArgs e)
        {
            FinalForm n = new FinalForm();

            n.Show();
        }