Ejemplo n.º 1
0
        private void year_btn_Click(object sender, RoutedEventArgs e)
        {
            string y = year.Text;

            iYear.Text = y;
            progressBar1.IsIndeterminate = true;
            progressBar2.IsIndeterminate = true;
            year_btn.IsEnabled           = false;
            UpdateMonth input = new UpdateMonth(y);

            backgroundWorkerUpdateMonth.RunWorkerAsync(input);
            //UpdateMonth(y);
        }
Ejemplo n.º 2
0
        private void backgroundWorker_DoWork(object sender, DoWorkEventArgs e)
        {
            // Get the input values.
            UpdateMonth input = (UpdateMonth)e.Argument;

            // Start the search for primes and wait.
            Month month = AsyncUpdateMonth(input.Year, backgroundWorkerUpdateMonth);

            UpdateMonth(month);
            if (backgroundWorkerUpdateMonth.CancellationPending)
            {
                e.Cancel = true;
                return;
            }
        }
Ejemplo n.º 3
0
        private void Month_Checked(object sender, RoutedEventArgs e)
        {
            string y = year.Text;

            TotalTip.Text    = "年度销售总额";
            MaxTip.Text      = "年度销售额最大月";
            MinTip.Text      = "年度销售额最小月";
            month.Visibility = Visibility.Collapsed;
            if (y == "")
            {
                ;
            }
            else
            {
                UpdateMonth input = new UpdateMonth(y);

                backgroundWorkerUpdateMonth.RunWorkerAsync(input);
                //UpdateMonth(y);
            }
        }
Ejemplo n.º 4
0
        private void Month_Checked(object sender, RoutedEventArgs e)
        {
            string y = year.Text;

            TotalTip.Text    = "年度销售总额";
            MaxTip.Text      = "年度销售额最大月";
            MinTip.Text      = "年度销售额最小月";
            month.Visibility = Visibility.Collapsed;
            //x轴
            string[] Labels = new[] { "一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月" };
            s1x.Labels = Labels;

            if (y == "")
            {
                ;
            }
            else
            {
                UpdateMonth input = new UpdateMonth(y);

                backgroundWorkerUpdateMonth.RunWorkerAsync(input);
                //UpdateMonth(y);
            }
        }