Exemple #1
0
        public Form1()
        {
            InitializeComponent();

            grpTimer.Paint += PaintBorderlessGroupBox;

            timePickerFrom.Format       = DateTimePickerFormat.Custom;
            timePickerFrom.CustomFormat = "HH:mm"; // Only use hours and minutes
            timePickerFrom.ShowUpDown   = true;

            backgroundWorker1.WorkerReportsProgress = true;
            backgroundWorker1.DoWork             += backgroundWorker1_DoWork;
            backgroundWorker1.ProgressChanged    += BackgroundWorker1_ProgressChanged;
            backgroundWorker1.RunWorkerCompleted += backgroundWorker1_RunWorkerCompleted;

            backgroundWorker2.DoWork             += backgroundWorker2_DoWork;
            backgroundWorker2.RunWorkerCompleted += backgroundWorker2_RunWorkerCompleted;

            progressBar1.Minimum = 0;
            progressBar1.Maximum = 5;
            progressBar1.Value   = 1;

            lastChecked = chbManchester;

            timer1.Enabled = false;
            seconds        = GetFrequencySeconds();
            txbFrequency_Leave(this, null);

            WindowExt.HalfSizeOnSecondaryMonitor(this);

            if (IsTimeRight)
            {
                KickOffSeleniumInBackground();
                //StartTimer();
            }
        }