コード例 #1
0
 public MaintDividend(Dividend dividend)
 {
     InitializeComponent();
     _dividend = dividend;
     cmbCorp.Enabled = false;
 }
コード例 #2
0
 public MaintDividend(PublicCorp corp)
 {
     InitializeComponent();
     _startCorp = corp;
     _dividend = new Dividend((corp == null ? 0 : corp.ID));
 }
コード例 #3
0
        public static void StoreDividend(Dividend div)
        {
            bool newRow = false;
            EMMADataSet.DividendsDataTable table = new EMMADataSet.DividendsDataTable();
            EMMADataSet.DividendsRow row;

            tableAdapter.FillByID(table, div.ID);
            if (table.Count > 0)
            {
                row = table[0];
            }
            else
            {
                row = table.NewDividendsRow();
                newRow = true;
            }

            row.CorpID = div.CorpID;
            row.DateTime = div.Date;
            row.PayoutPerShare = div.PayoutPerShare;

            if (newRow)
            {
                table.AddDividendsRow(row);
            }

            tableAdapter.Update(table);
        }
コード例 #4
0
 public MaintDividend()
 {
     InitializeComponent();
     _dividend = new Dividend(0);
 }
コード例 #5
0
 private void dividendGrid_CellEnter(object sender, DataGridViewCellEventArgs e)
 {
     if (dividendGrid.Rows[e.RowIndex] != null)
     {
         _currentDiv = (Dividend)dividendGrid.Rows[e.RowIndex].DataBoundItem;
     }
     else
     {
         _currentDiv = null;
     }
 }