Ejemplo n.º 1
0
 /// <summary>
 /// Function to fill Datagridview
 /// </summary>
 public void StockJournalRegisterGrideFill()
 {
     try
     {
         DataTable dtblReg = new DataTable();
         dtblReg = spStockJournalMaster.StockJournalRegisterGrideFill(Convert.ToDateTime(txtFromDate.Text), Convert.ToDateTime(txtToDate.Text), txtVoucherNo.Text);
         dgvStockJournalRegister.DataSource = dtblReg;
     }
     catch (Exception ex)
     {
         MessageBox.Show("SJREG:2" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
        /// <summary>
        /// Function to get values from StockJournal Table based on parameter for register
        /// </summary>
        /// <param name="fromDate"></param>
        /// <param name="toDate"></param>
        /// <param name="voucherNo"></param>
        /// <returns></returns>
        public List <DataTable> StockJournalRegisterGrideFill(DateTime fromDate, DateTime toDate, string invoiceNo)
        {
            List <DataTable> listObj = new List <DataTable>();

            try
            {
                listObj = spStockJournalMaster.StockJournalRegisterGrideFill(fromDate, toDate, invoiceNo);
            }
            catch (Exception ex)
            {
                MessageBox.Show("AL6:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
            return(listObj);
        }