/// <summary> /// Function to Fill product group or tax according to search by combo box selection in Product Group/Tax combo box /// </summary> public void ProductGroupTaxComboFill() { try { if (cmbSearchBy.SelectedIndex == 0) { ProductGroupSP spProductGroup = new ProductGroupSP(); DataTable dtblProductGroup = new DataTable(); dtblProductGroup = spProductGroup.ProductGroupViewAll(); cmbProductGroupTax.DataSource = dtblProductGroup; cmbProductGroupTax.ValueMember = "groupId"; cmbProductGroupTax.DisplayMember = "groupName"; } else { TaxSP spTax = new TaxSP(); DataTable dtblTax = new DataTable(); dtblTax = spTax.TaxViewAll(); cmbProductGroupTax.DataSource = dtblTax; cmbProductGroupTax.ValueMember = "taxId"; cmbProductGroupTax.DisplayMember = "taxName"; } } catch (Exception ex) { formMDI.infoError.ErrorString = "CPT 5 : " + ex.Message; } }
/// <summary> /// Function to Fill product group or tax according to search by combo box selection in Product Group/Tax combo box /// </summary> public void ProductGroupTaxComboFill() { try { if (cmbSearchBy.SelectedIndex == 0) { ProductGroupSP spProductGroup = new ProductGroupSP(); DataTable dtblProductGroup = new DataTable(); dtblProductGroup = spProductGroup.ProductGroupViewAll(); cmbProductGroupTax.DataSource = dtblProductGroup; cmbProductGroupTax.ValueMember = "groupId"; cmbProductGroupTax.DisplayMember = "groupName"; } else { TaxSP spTax = new TaxSP(); DataTable dtblTax = new DataTable(); dtblTax = spTax.TaxViewAll(); cmbProductGroupTax.DataSource = dtblTax; cmbProductGroupTax.ValueMember = "taxId"; cmbProductGroupTax.DisplayMember = "taxName"; } } catch (Exception ex) { MessageBox.Show("CPT 5 : " + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }
/// <summary> /// Function to Fill new tax type combo box /// </summary> public void NewTaxTypeComboFill() { try { TaxSP spTax = new TaxSP(); DataTable dtblTax = new DataTable(); dtblTax = spTax.TaxViewAll(); cmbNewTaxType.DataSource = dtblTax; cmbNewTaxType.ValueMember = "taxId"; cmbNewTaxType.DisplayMember = "taxName"; } catch (Exception ex) { formMDI.infoError.ErrorString = "CPT 4 : " + ex.Message; } }
/// <summary> /// Function to Fill new tax type combo box /// </summary> public void NewTaxTypeComboFill() { try { TaxSP spTax = new TaxSP(); DataTable dtblTax = new DataTable(); dtblTax = spTax.TaxViewAll(); cmbNewTaxType.DataSource = dtblTax; cmbNewTaxType.ValueMember = "taxId"; cmbNewTaxType.DisplayMember = "taxName"; } catch (Exception ex) { MessageBox.Show("CPT 4 : " + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }
/// <summary> /// Function to fill the tax combobox /// </summary> public void TaxFill() { try { TaxSP spTax = new TaxSP(); DataTable dt = new DataTable(); dt = spTax.TaxViewAll(); DataRow dr = dt.NewRow(); dr[1] = "All"; dt.Rows.InsertAt(dr, 0); cmbTax.ValueMember = "taxId"; cmbTax.DisplayMember = "taxName"; cmbTax.DataSource = dt; } catch (Exception ex) { MessageBox.Show("VRR:05" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }
/// <summary> /// Function to fill the tax combobox /// </summary> public void TaxFill() { try { TaxSP spTax = new TaxSP(); DataTable dt = new DataTable(); dt = spTax.TaxViewAll(); DataRow dr = dt.NewRow(); dr[1] = "All"; dt.Rows.InsertAt(dr, 0); cmbTax.ValueMember = "taxId"; cmbTax.DisplayMember = "taxName"; cmbTax.DataSource = dt; } catch (Exception ex) { formMDI.infoError.ErrorString = "VRR5:" + ex.Message; } }
/// <summary> /// To fill the tax combobox /// </summary> public void TaxComboFill() { try { DataTable dtbl = new DataTable(); TaxSP spTax = new TaxSP(); dtbl = spTax.TaxViewAll(); DataRow dr = dtbl.NewRow(); dr["taxName"] = "All"; dr["taxId"] = 0; dtbl.Rows.InsertAt(dr, 0); cmbTax.DataSource = dtbl; cmbTax.DisplayMember = "taxName"; cmbTax.ValueMember = "taxId"; } catch (Exception ex) { MessageBox.Show("TR:2" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }
/// <summary> /// To fill the tax combobox /// </summary> public void TaxComboFill() { try { DataTable dtbl = new DataTable(); TaxSP spTax = new TaxSP(); dtbl = spTax.TaxViewAll(); DataRow dr = dtbl.NewRow(); dr["taxName"] = "All"; dr["taxId"] = 0; dtbl.Rows.InsertAt(dr, 0); cmbTax.DataSource = dtbl; cmbTax.DisplayMember = "taxName"; cmbTax.ValueMember = "taxId"; } catch (Exception ex) { formMDI.infoError.ErrorString = "TR2:" + ex.Message; } }
/// <summary> /// Function to Fill product group or tax according to search by combo box selection in Product Group/Tax combo box /// </summary> public void ProductGroupTaxComboFill() { try { if (cmbSearchBy.SelectedIndex == 0) { ProductGroupSP spProductGroup = new ProductGroupSP(); DataTable dtblProductGroup = new DataTable(); dtblProductGroup = spProductGroup.ProductGroupViewAll(); cmbProductGroupTax.DataSource = dtblProductGroup; cmbProductGroupTax.ValueMember = "groupId"; cmbProductGroupTax.DisplayMember = "groupName"; } else { TaxSP spTax = new TaxSP(); DataTable dtblTax = new DataTable(); dtblTax = spTax.TaxViewAll(); cmbProductGroupTax.DataSource = dtblTax; cmbProductGroupTax.ValueMember = "taxId"; cmbProductGroupTax.DisplayMember = "taxName"; } } catch (Exception ex) { MessageBox.Show("CPT 5 : " + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }
/// <summary> /// Function to Fill new tax type combo box /// </summary> public void NewTaxTypeComboFill() { try { TaxSP spTax = new TaxSP(); DataTable dtblTax = new DataTable(); dtblTax = spTax.TaxViewAll(); cmbNewTaxType.DataSource = dtblTax; cmbNewTaxType.ValueMember = "taxId"; cmbNewTaxType.DisplayMember = "taxName"; } catch (Exception ex) { MessageBox.Show("CPT 4 : " + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }