Beispiel #1
0
        private void updateLabels() //acts as push data
        {
            _TempTour.ID = txtID.Text;
            _TempTour.TourDescription = txtDescription.Text;
            _TempTour.Passenger       = nupPassanger.Value;
            _TempTour.Distance        = nupDistance.Value;
            _TempTour.StartDate       = dtpStart.Value;
            _TempTour.EndDate         = dtpEnd.Value;

            dtpStart.MaxDate = _TempTour.EndDate;
            dtpEnd.MinDate   = _TempTour.StartDate;

            _TempTour.MarkUp = nupMarkup.Value;

            lstCost.DataSource = null;
            lstCost.DataSource = _TempTour.CostList;

            //Read only feilds, will be changed once editing has been done
            lblTotalCost.Text = string.Format("{0:C}", _TempTour.calcTourCost());
            lblPricepp.Text   = string.Format("{0:C}", _TempTour.Pricepp());
        }