IMsProblemCalculation.Variables

Syntax

Variables: IMsVariables;

Description

The Variables property returns the variables collection, which data is used at in calculation of this modeling problem.

Comments

The property is outdated, use IMsProblemCalculation.VariableStubs.

Example

Sub Main;

Var

MB: IMetabase;

Problem: IMsProblem;

CalcSett: IMsProblemCalculationSettings;

Calculation: IMsProblemCalculation;

i: Integer;

Begin

MB := MetabaseClass.Active;

Problem := MB.ItemByIdNamespace("PROBLEM_1", MB.ItemById("KONT_MODEL").Key).Bind As IMsProblem;

CalcSett := Problem.CreateCalculationSettings;

Calculation := Problem.Calculate(CalcSett);

For i := 0 To Calculation.Variables.Count - 1 Do

Debug.WriteLine((Calculation.Variables.Item(i) As IMetabaseObject).Name);

End For;

End Sub Main;

After executing the example the list of input and output variables is displayed in the console, which data is used on problem calculation with the PROBLEM_1 identifier.

See also:

IMsProblemCalculation