Exemplo n.º 1
0
        private void GoToCart(object sender, EventArgs e) //opens cart form
        {
            try
            {
                cartCount = GameDB.CheckCartCount();
            }
            catch (SqlException ex)
            {
                MessageBox.Show(ex.Message, ex.GetType().ToString());
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, ex.GetType().ToString());
            }

            if (cartCount != 0)
            {
                this.Close(); //close wishlist form
                frmCart cartForm = new frmCart();
                cartForm.ShowDialog();
            }
            else
            {
                MessageBox.Show("No items in cart.");
            }
        }
Exemplo n.º 2
0
 private void GoToCart(object sender, EventArgs e) //this goes to the cart checkout form if there are items in the cart
 {
     if (cartCount != 0)
     {
         frmCart cartForm = new frmCart();
         cartForm.ShowDialog();
     }
     else
     {
         MessageBox.Show("No items in cart.");
     }
 }