Exemple #1
0
 private void btnAddProduct_Click(object sender, EventArgs e)
 {
     if (radActive.Checked == true)
     {
         frmProducts prod = new frmProducts();
         if (clientID == 0)
         {
             MessageBox.Show("A product must have an owner. Please choose a CLIENT first then try again.", "Information", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
         }
         else
         {
             prod.ClientID = clientID;
             prod.ClientClassificationID = client_classification_id;
             prod.Show();
         }
     }
     else
     {
         MessageBox.Show("You cannot add a product to an INACTIVE Client", "Information", MessageBoxButtons.OK, MessageBoxIcon.Warning);
     }
 }
Exemple #2
0
 private void btnUpdateProduct_Click(object sender, EventArgs e)
 {
     if (radActive.Checked == true)
     {
         frmProducts prod = new frmProducts();
         if (radActiveProducts.Checked == true)
         {
             prod.ActiveInactive = true;
         }
         else if (radInactiveProducts.Checked == true)
         {
             prod.ActiveInactive = false;
         }
         prod.ClientID  = clientID;
         prod.ProductID = product_id;
         prod.ClientClassificationID = client_classification_id;
         prod.Show();
     }
     else
     {
         MessageBox.Show("You cannot update a product to an INACTIVE Client", "Information", MessageBoxButtons.OK, MessageBoxIcon.Warning);
     }
 }