Esempio n. 1
0
        // Do next week's Processing
        private void button1_Click(object sender, EventArgs e)
        {
            if (fund.FundHistory[fund.FundHistory.Count - 1].WeeklyDate.AddDays(7) > DateTime.Today)
            {
                MessageBox.Show("You cannot complete the processing until the close on Friday " + fund.FundHistory[fund.FundHistory.Count - 1].WeeklyDate.AddDays(7).ToShortDateString() + ".");
                return;
            }

               Processor nextProc = Util.DeepClone<Processor>(fund.FundHistory[fund.FundHistory.Count - 1]);
               nextProc.WeeklyDate = nextProc.WeeklyDate.AddDays(+7);
               nextProc.StockPick = "";
               WeeklyProcessor currentWeeksProcessorForm = new WeeklyProcessor(this, fund.FundHistory.Count - 1);
               currentWeeksProcessorForm.Show();
        }
Esempio n. 2
0
        public StockPickerForm(TrendUniverse StockUni, WeeklyProcessor parent)
        {
            FormParent = parent;
            TrendUni = FormParent.weeksProcessData.Universe;
            bs.DataSource = TrendUni.TrendsUniverseContents;
            InitializeComponent();
            dataGridView2.AutoGenerateColumns = false;
            dataGridView2.DataSource = TrendUni.TrendsUniverseContents;
            DataGridViewTextBoxColumn col = new DataGridViewTextBoxColumn();
            col.DataPropertyName = "Symbol";
            dataGridView2.Columns.Add(col);

            dataGridView1.DataSource = TrendUni.TrendsUniverseContents;

            monthCalendar1.SelectionEnd = FormParent.weeksProcessData.WeeklyDate;
            label_Date.Text = FormParent.weeksProcessData.WeeklyDate.ToShortDateString();
            monthCalendar1.Enabled = false;
          
        }
Esempio n. 3
0
 private void OnCellDoubleClick(object sender, DataGridViewCellEventArgs e)
 {
     int RowIndex = fund.FundHistory.Count - e.RowIndex - 1;
     if (RowIndex > 0)
     {
         WeeklyProcessor WP = new WeeklyProcessor(fund.FundHistory[RowIndex], fund.FundHistory[RowIndex + -1]);
         WP.Show();
     }
 }