예제 #1
0
        public Stock()
        {
            InitializeComponent();
            var grid_control = new data_grid_controls();

            grid_control.show_grid_view(dataGridView1);
            grid_control.combo_box_suggestions(comboBox1);
            grid_control.product_suggestions(comboBox2);
            grid_control.product_suggestions(comboBox3);
            grid_control.supplier_suggestions(comboBox5);
        }
예제 #2
0
        private void button1_Click_2(object sender, EventArgs e)
        {
            var grid_controls = new data_grid_controls();

            this.Controls.Clear();
            InitializeComponent();
            grid_controls.show_grid_view(dataGridView1);
            grid_controls.combo_box_suggestions(comboBox1);
            grid_controls.product_suggestions(comboBox2);
            grid_controls.product_suggestions(comboBox3);
            grid_controls.supplier_suggestions(comboBox5);
        }
예제 #3
0
        private void button5_Click(object sender, EventArgs e)
        {
            var grid_control = new data_grid_controls();

            if (string.IsNullOrWhiteSpace(textBox1.Text) || string.IsNullOrWhiteSpace(textBox2.Text) || string.IsNullOrWhiteSpace(comboBox5.Text))
            {
                MessageBox.Show("Please fill all the fields");
            }
            else
            {
                grid_control.add_product(textBox1, textBox2, comboBox5);
            }
            this.Controls.Clear();
            InitializeComponent();
            grid_control.show_grid_view(dataGridView1);
            grid_control.combo_box_suggestions(comboBox1);
            grid_control.product_suggestions(comboBox2);
            grid_control.product_suggestions(comboBox3);
            grid_control.supplier_suggestions(comboBox5);
        }