Ejemplo n.º 1
0
        private void MainForm_Load(object sender, EventArgs e)
        {
            lstTruckOrder.Items.Clear();
            lstSkip.Items.Clear();

            presenter = new Presenter(this);
            presenter.Show();

            LoadImages();

            LoadData();

            lblNrCrt.DataBindings.Add("Text", this, "AutoIncrementNrCrt");

            Timer regUpdater = new Timer();
            regUpdater.Tick += RegUpdater_Tick;
            regUpdater.Interval = 1000;
            regUpdater.Start();

            Timer raportTimer = new Timer();
            DateTime tick = DateTime.Now;
            tick = tick.AddHours(-tick.Hour).AddMinutes(-tick.Minute).AddSeconds(-tick.Second);
            tick = tick.AddDays(1);
            raportTimer.Interval = (int)(tick - DateTime.Now).TotalMilliseconds;
            raportTimer.Tick += RaportTimer_Tick;
            raportTimer.Start();
        }
Ejemplo n.º 2
0
 private void cmdShowPresenter_Click(object sender, EventArgs e)
 {
     if (presenter != null) {
         if (!presenter.Visible) {
             presenter.Dispose();
             presenter = new Presenter(this);
             presenter.UpdatePresenterSettings();
             presenter.Show();
         }
     } else {
         presenter = new Presenter(this);
         presenter.Show();
     }
 }