public void LoadInData()
 {
     //reads the data from the array and adds it to the correct text boxes
     txtMonthId.Text         = selectedMonth.GetMonthId().ToString();
     txtMaxTemp.Text         = selectedMonth.GetMaxTemp().ToString();
     txtMinTemp.Text         = selectedMonth.GetMinTemp().ToString();
     txtNumOfAirFrost.Text   = selectedMonth.GetNumAirFrostDays().ToString();
     txtMmsOfRainfall.Text   = selectedMonth.GetMmsOfRainfall().ToString();
     txtHoursOfSunshine.Text = selectedMonth.GetHoursOfSunshine().ToString();
 }
Esempio n. 2
0
        public void LoadObseravations()
        {
            //adds all of the info to the observations list box
            lstObservations.Items.Clear();
            MonthlyObservations tempMonth = Data.Locations[lstLocationNames.SelectedIndex].GetYears()[lstYears.SelectedIndex].GetMonthlyObservations()[lstMonths.SelectedIndex];

            lstObservations.Items.Add("MonthID; " + tempMonth.GetMonthId().ToString());
            lstObservations.Items.Add("MaxTemp: " + tempMonth.GetMaxTemp().ToString());
            lstObservations.Items.Add("MinTemp: " + tempMonth.GetMinTemp().ToString());
            lstObservations.Items.Add("Number Of Days Of Air Frost: " + tempMonth.GetNumAirFrostDays().ToString());
            lstObservations.Items.Add("Millimetres Of Rainfall: " + tempMonth.GetMmsOfRainfall().ToString());
            lstObservations.Items.Add("Hours Of Sunshine: " + tempMonth.GetHoursOfSunshine().ToString());
        }