IMsProblemDimensionFix.Selection

Syntax

Selection: IDimSelectionSet;

Description

The Selection property returns an object that contains selection by all fixed dimensions.

Example

Executing the example requires that the modeling container includes a variable that is adjusted to data loading by means of the formula.

 

Sub Main;

Var

MB: IMetabase;

MObj: IMetabaseObject;

Variable: IMsVariable;

LoadSetting: IMsVariableLoadSettings;

Period: IMsModelPeriod;

i: Integer;

Begin

MB := MetabaseClass.Active;

MObj := MB.ItemByIdNamespace("Var_1", MB.ItemById("KONT_MODEL").Key).Edit;

Variable := MObj As IMsVariable;

LoadSetting := Variable.CreateLoadSettings;

Period := LoadSetting.Period;

Period.IdentificationStartDate := DateTime.ComposeDay(2000, 1, 1);

Period.IdentificationEndDate := DateTime.ComposeDay(2004, 1, 1);

LoadSetting.ScenarioIncluded(-1) := True;

For i := 0 To LoadSetting.DimensionFix.Count - 1 Do

LoadSetting.DimensionFix.Selection.Item(i).SelectAll;

End For;

Variable.Execute(LoadSetting);

MObj.Save;

End Sub Main;

After executing the example the parameters that are necessary for data loading into the variable are determined. If variable's structure contains additional dimensions, the data is loaded for all the elements in these dimensions. Then the data is loaded.

See also:

IMsProblemDimensionFix