示例#1
0
 /// <summary>
 /// Function to fill Cash/Bank combobox
 /// </summary>
 public void LedgerComboFill()
 {
     try
     {
         DataTable dtbl = new DataTable();
         TransactionsGeneralFill obj = new TransactionsGeneralFill();
         dtbl = obj.BankOrCashComboFill(false);
         DataRow dr = dtbl.NewRow();
         dr[0] = "All";
         dr[1] = 0;
         dtbl.Rows.InsertAt(dr, 0);
         cmbAccountLedger.DataSource    = dtbl;
         cmbAccountLedger.DisplayMember = "ledgerName";
         cmbAccountLedger.ValueMember   = "ledgerId";
     }
     catch (Exception ex)
     {
         MessageBox.Show("PREG2:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }