// // called on Year change. private void RefreshReportPeriodList(object sender, EventArgs e) { if (cmbYearEnding.SelectedIndex > -1) { TFinanceControls.InitialiseAvailableFinancialPeriodsList( ref cmbReportPeriod, FLedgerNumber, cmbYearEnding.GetSelectedInt32(), FLedgerRow.CurrentPeriod, false); } }
/// <summary> /// Update the Period ComboBox after a change to the Year /// </summary> /// <param name="ASelectedYear">The year for which to display the periods</param> public void RefreshPeriods(Int32 ASelectedYear) { bool IncludeCurrentAndForwardingItem = true; //Determine whether or not to include the "Current and forwarding periods" item in the period combo if (FMainDS.ALedger.Rows.Count == 1) { IncludeCurrentAndForwardingItem = (ASelectedYear == FMainDS.ALedger[0].CurrentFinancialYear); } //Update the periods for the newly selected year TFinanceControls.InitialiseAvailableFinancialPeriodsList(ref FcmbPeriod, FLedgerNumber, ASelectedYear, 0, IncludeCurrentAndForwardingItem); }
private void RefreshPeriods(Int32 ASelectedYear) { bool IncludeCurrentAndForwardingItem = true; //Determine whether or not to include the "Current and forwarding periods" item in the period combo if (FMainDS.ALedger.Rows.Count == 1) { IncludeCurrentAndForwardingItem = (ASelectedYear == FMainDS.ALedger[0].CurrentFinancialYear); } //TLogging.Log("Populating Period List ..."); TFinanceControls.InitialiseAvailableFinancialPeriodsList(ref FcmbPeriod, FLedgerNumber, ASelectedYear, 0, IncludeCurrentAndForwardingItem); //TLogging.Log("Period List done!"); }