IAlgorithmParamValue.Name

Syntax

Name: String;

None;

Description

The Name property returns the parameter name.

Example

Executing the example requires that the repository contains a calculation algorithm with the ALGORITHM identifier. The calculation algorithm should contain at least one parameter.

Add a link to the Calculation Algorithm Core custom assembly contained in the Calculation Algorithms component, and links to the Algo, Metabase, Transform system assemblies.

Sub UserProc;
Var
    MB: IMetabase;
    MObj: IMetabaseObjectDescriptor;
    Algo: ICalcObject;
    CalcAlgo: ICalcAlgorithm;
    ParamValues: IAlgorithmParameterValues;
    ValueList: IAlgorithmParamValueList;
    Param: IAlgorithmParamValue;
    ParamType: String;
Begin
    MB := MetabaseClass.Active;
    
// Get calculation algorithm
    MObj := MB.ItemById("ALGORITHM");
    Algo := CalcObjectFactory.CreateCalcObject(MObj, 
True);
    CalcAlgo := Algo 
As ICalcAlgorithm;
    
// Get collection of calculation algorithm parameters
    ParamValues := CalcAlgo.ParamValues;
    ValueList := ParamValues.Values;
    
// Get the first parameter and display its settings in the console
    Param := ValueList.Item(0);
    Debug.WriteLine(
"Name: " + Param.Name);
    Debug.WriteLine(
"Identifier: " + Param.Id);
    
Select Case Param.ParamType As Integer
        
Case 0: ParamType := "Type is not set";
        
Case 1: ParamType := "Numeric or string value";
        
Case 2: ParamType := "Data series";
        
Case 3: ParamType := "Date";
        
Case 4: ParamType := "Period";
        
Case 5: ParamType := "Dictionary elements selection";
        
Case 6: ParamType := "Frequency";
    
End Select;
    Debug.WriteLine(
"Parameter type: " + ParamType);
    Debug.WriteLine(
"Dictionary: " + Param.LinkedObject.Name);
End Sub UserProc;

Not provisioned.

After executing the example the console displays settings of the first parameter:

Name: Planning version

Identifier: PLANNING_VERSION

Parameter type: Dictionary elements selection

Dictionary: Planning versions

See also:

IAlgorithmParamValue