private void tsbAddProduct_Click(object sender, EventArgs e) { AddProduct frmAddProduct = new AddProduct(); pnlMain.Controls.Clear(); frmAddProduct.ShowDialog(); }
private void btnAdd_Click(object sender, EventArgs e) { AddProduct frmAddProduct = new AddProduct(); frmAddProduct.CallFromUserControll = this; frmAddProduct.ShowDialog(); }
private void btnCreateSP_Click(object sender, EventArgs e) { AddProduct frmProduct = new AddProduct(); if (frmProduct.ShowDialog() == System.Windows.Forms.DialogResult.OK) { ProductAttributeService productAttrService = new ProductAttributeService(); products = new BindingList <ProductAttributeModel>(productAttrService.GetProductAndAttribute()); ((DataGridViewComboBoxColumn)dgvStockEntranceDetails.Columns[0]).DataSource = products; } }
private void dgvProductList_CellDoubleClick(object sender, DataGridViewCellEventArgs e) { AddProduct frmAddProductType = new AddProduct(); DataGridViewRow currentRow = dgvProductList.Rows[e.RowIndex]; int id = ObjectHelper.GetValueFromAnonymousType <int>(currentRow.DataBoundItem, "Id"); frmAddProductType.loadDataForEditProduct(id); frmAddProductType.CallFromUserControll = this; frmAddProductType.ShowDialog(); }
private void dgvProductList_CellDoubleClick(object sender, DataGridViewCellEventArgs e) { AddProduct frmAddProductType = new AddProduct(); DataGridViewRow currentRow = dgvProductList.Rows[e.RowIndex]; int id = ObjectHelper.GetValueFromAnonymousType<int>(currentRow.DataBoundItem, "Id"); frmAddProductType.loadDataForEditProduct(id); frmAddProductType.CallFromUserControll = this; frmAddProductType.ShowDialog(); }
private void btnCreateSP_Click(object sender, EventArgs e) { AddProduct frmProduct = new AddProduct(); if (frmProduct.ShowDialog() == System.Windows.Forms.DialogResult.OK) { ProductAttributeService productAttrService = new ProductAttributeService(); products = new BindingList<ProductAttributeModel>(productAttrService.GetProductAndAttribute()); ((DataGridViewComboBoxColumn)dgvStockEntranceDetails.Columns[0]).DataSource = products; } }