IMsModelPeriod.ForecastEndDate

Syntax

ForecastEndDate: DateTime;

Description

The ForecastEndDate property determines forecasting period end date.

Example

Executing the example requires that the repository contains a modeling container with the MODEL_SPACE identifier. The model with the MODEL_1 identifier is created in the container.

Add links to the Metabase and Ms system assemblies.

Sub UserProc;
Var
    MB: IMetabase;
    Model: IMsModel;
    Period: IMsModelPeriod;
Begin
    // Get the current repository
    MB := MetabaseClass.Active;
    // Get model
    Model := MB.ItemByIdNamespace("MODEL_1", MB.ItemById("MODEL_SPACE").Key).Edit As IMsModel;
    // Get model periods
    Period := Model.Transform.Period;
    // Set sample period conditions
    Period.IdentificationStartDate := DateTime.ComposeDay(200011);
    Period.IdentificationEndDate := DateTime.ComposeDay(20051231);
    // Set forecasting period conditions
    Period.ForecastStartDate := DateTime.ComposeDay(200611);
    Period.ForecastEndDate := DateTime.ComposeDay(20101231);
    // Set use of specified periods
    Model.UseModelPeriod := True;
    // Save changes
    (Model As IMetabaseObject).Save;
End Sub UserProc;

After executing the example sample and forecasting periods are changed for the model. The time series use of specified periods on problem calculation is also set for model.

See also:

IMsModelPeriod