Exemplo n.º 1
0
        private void btnAddNew_Click(object sender, EventArgs e)
        {
            var frmProduct = new FormProductMaintenance();
            var result     = frmProduct.ShowDialog();

            if (result == DialogResult.OK)
            {
                LoadContent();
            }
        }
Exemplo n.º 2
0
        private void btnEdit_Click(object sender, EventArgs e)
        {
            int id      = (int)ProductList.CurrentRow.Cells[0].Value;
            var product = PrdApi.ProductList.FirstOrDefault(t => t.Id == id);

            var frmProduct = new FormProductMaintenance(product);
            var result     = frmProduct.ShowDialog();

            if (result == DialogResult.OK)
            {
                LoadContent();
            }
        }