Пример #1
0
 private void AddToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (treeView1.SelectedNode.Parent == null)
     {
         AddCategoryForm addForm = new AddCategoryForm();
         addForm.Owner = this;
         addForm.Show();
     }
     else if (treeView1.SelectedNode.Parent.Parent != null || treeView1.SelectedNode.Parent == categoryRootNode)
     {
         AddProductForm addForm = new AddProductForm();
         addForm.Owner = this;
         addForm.Show();
     }
 }
Пример #2
0
 public void AddShow()
 {
     addProductForm.Show();
     addProductEvents();
 }