Exemple #1
0
 public Form1()
 {
     InitializeComponent();
     JobMethods.LoadJobList(Jobs, path, dataGridView1);
     dataGridView1.Update();
     // schedule_Timer(Jobs);
 }
Exemple #2
0
        private void button3_Click(object sender, EventArgs e)//edit
        {
            jobSchedule Job  = (jobSchedule)dataGridView1.CurrentRow.DataBoundItem;
            EditForm    edit = new EditForm();

            edit.EditJob(Job);

            DialogResult dr = edit.ShowDialog();

            if (dr == DialogResult.OK)
            {
                dataGridView1.Refresh();
            }
            JobMethods.SaveJobList(Jobs, path);
        }
Exemple #3
0
        private void button1_Click(object sender, EventArgs e)//add
        {
            job = new jobSchedule();
            EditForm edit = new EditForm();

            edit.EditJob(job);
            DialogResult dr = edit.ShowDialog();

            if (dr == DialogResult.OK)
            {
                Jobs.Add(job);
                DataGridRefresh();
            }

            JobMethods.SaveJobList(Jobs, path);
        }
Exemple #4
0
 private void button2_Click(object sender, EventArgs e)//delete
 {
     JobMethods.DeleteSelectedJob(Jobs, dataGridView1, path);
 }