Exemple #1
0
        /// <summary>
        ///Function to get all the values from VoucherType Table
        /// </summary>
        /// <returns></returns>
        public List <DataTable> VoucherTypeViewAll()
        {
            List <DataTable> listObj = new List <DataTable>();

            try
            {
                listObj = spVoucherType.VoucherTypeViewAll();
            }
            catch (Exception ex)
            {
                MessageBox.Show("VT13:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
            return(listObj);
        }
Exemple #2
0
 /// <summary>
 /// Function to fill Voucher no combobox
 /// </summary>
 public void VoucherComboFill()
 {
     try
     {
         VoucherTypeSP SpVoucherType = new VoucherTypeSP();
         DataTable     dtbl          = new DataTable();
         dtbl = SpVoucherType.VoucherTypeViewAll();
         DataRow dr = dtbl.NewRow();
         dr[0] = 0;
         dr[1] = "All";
         dtbl.Rows.InsertAt(dr, 0);
         cmbVoucherType.DataSource    = dtbl;
         cmbVoucherType.ValueMember   = "voucherTypeId";
         cmbVoucherType.DisplayMember = "voucherTypeName";
         cmbVoucherType.SelectedIndex = 0;
     }
     catch (Exception ex)
     {
         MessageBox.Show("RRP4:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }