/// <summary> /// Function to fill batch combobox for production /// </summary> public void BatchComboFillProduction(decimal decProductId, int inRow, int inColumn) { try { DataTable dtbl = new DataTable(); BatchSP spBatch = new BatchSP(); dtbl = spBatch.BatchNamesCorrespondingToProduct(decProductId); DataGridViewComboBoxCell dgvcmbBatchCell = (DataGridViewComboBoxCell)dgvProduction.Rows[inRow].Cells[inColumn]; dgvcmbBatchCell.DataSource = dtbl; dgvcmbBatchCell.ValueMember = "batchId"; dgvcmbBatchCell.DisplayMember = "batchNo"; } catch (Exception ex) { MessageBox.Show("SJ:10" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }