Пример #1
0
        /// <summary>
        /// 增加持仓股票信息按钮事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void txtHoldAdd_Click(object sender, EventArgs e)
        {
            FrmStockHoldAdd frmHoldAdd = new FrmStockHoldAdd();

            frmHoldAdd.SetHold += GetStockHold;
            frmHoldAdd.ShowDialog();
            dgv_HoldStock.DataSource = dt_holdstock;
        }
Пример #2
0
        /// <summary>
        /// 股票持仓信息修改事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void ModifyHoldStock(object sender, EventArgs e)
        {
            FrmStockHoldAdd frmHoldAdd = new FrmStockHoldAdd();

            frmHoldAdd.AddFlag  = false;
            frmHoldAdd.modifyId = Convert.ToInt32(dgv_HoldStock.SelectedRows[0].Cells["ID"].Value.ToString());
            frmHoldAdd.SetHold += GetStockHold;
            frmHoldAdd.ShowDialog();
            dgv_HoldStock.DataSource = dt_holdstock;
        }