Ejemplo n.º 1
0
 //Method for the event to go to a specific form if a farmer that exists is selected
 private void NavResumeOrFarmView(Farmer CurrentFarmer)
 {
     if (CurrentFarmer.GetFarmSize() > 0)
     {
         if (CurrentFarmer.numOfAnimals() > 0)
         {
             Farm_View form = new Farm_View(CurrentFarmer.ID);
             this.Hide();
             form.ShowDialog();
             this.Close();
         }
         else
         {
             Animal_Selection form = new Animal_Selection(CurrentFarmer.ID, CurrentFarmer.GetFarmSize());
             this.Hide();
             form.ShowDialog();
             this.Close();
         }
     }
     else
     {
         Farm_Creation form = new Farm_Creation(CurrentFarmer.ID);
         this.Hide();
         form.ShowDialog();
         this.Close();
     }
 }
Ejemplo n.º 2
0
        private void TimerNew_Tick(object sender, EventArgs e)
        {
            timerNew.Stop();
            Cursor.Current = Cursors.Default;

            Farm_View form = new Farm_View(ID);

            this.Hide();
            form.ShowDialog();
            this.Close();
        }