public DashboardData(Company objCompany, BudgetTypeHandler handler, int periodDays, int periodCount, DateTime startDate) { Company = objCompany; Handler = handler; PeriodDays = periodDays; PeriodCount = periodCount; StartDate = startDate; EndDate = startDate.AddDays(periodCount * periodDays - 1); BudgetDetailRows = new Dictionary <string, BudgetDetailRow>(); SplitDetailRows = new Dictionary <string, SplitDetailRow>(); }
private void cmdOkay_Click(object sender, EventArgs e) { Handler = (BudgetTypeHandler)cboBudgetType.SelectedItem; StartDate = ctlStartDate.Value.Date; if (int.TryParse(txtPeriodDays.Text, out PeriodDays)) { if (int.TryParse(txtPeriodCount.Text, out PeriodCount)) { this.DialogResult = DialogResult.OK; this.Close(); return; } } HostUI.ErrorMessageBox("Invalid budget specs"); }