Esempio n. 1
0
 private void editToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (!employeeToolStripMenuItem.Enabled)
     {
         AddEmployee f = new AddEmployee(this, dataGridView1.SelectedRows[0]);
         f.ShowDialog();
     }
     if (!positionsToolStripMenuItem.Enabled)
     {
         AddPosition f = new AddPosition(this, dataGridView1.SelectedRows[0]);
         f.ShowDialog();
     }
     if (!sellingPlansToolStripMenuItem.Enabled)
     {
         AddPlan f = new AddPlan(this, dataGridView1.SelectedRows[0]);
         f.ShowDialog();
     }
     if (!productsToolStripMenuItem.Enabled)
     {
         AddProduct f = new AddProduct(this, dataGridView1.SelectedRows[0]);
         f.ShowDialog();
     }
     //if (!sellsToolStripMenuItem.Enabled)
     //{
     //    AddSell f = new AddSell(dataGridView1.SelectedRows[0].Index);
     //    f.ShowDialog();
     //}
     //if (!suppliesToolStripMenuItem.Enabled)
     //{
     //    AddSupply f = new AddSupply(dataGridView1.SelectedRows[0].Index);
     //    f.ShowDialog();
     //}
 }
Esempio n. 2
0
 private void addToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (!employeeToolStripMenuItem.Enabled)
     {
         AddEmployee f = new AddEmployee(this);
         f.ShowDialog();
     }
     if (!positionsToolStripMenuItem.Enabled)
     {
         AddPosition f = new AddPosition(this);
         f.ShowDialog();
     }
     if (!sellingPlansToolStripMenuItem.Enabled)
     {
         AddPlan f = new AddPlan(this);
         f.ShowDialog();
     }
     if (!productsToolStripMenuItem.Enabled)
     {
         AddProduct f = new AddProduct(this);
         f.ShowDialog();
     }
     //if (!sellsToolStripMenuItem.Enabled)
     //{
     //    AddSell f = new AddSell(-1);
     //    f.ShowDialog();
     //}
     //if (!suppliesToolStripMenuItem.Enabled)
     //{
     //    AddSupply f = new AddSupply(-1);
     //    f.ShowDialog();
     //}
 }