How to assign values to a tabular parameter via Scripting?

Category:
Scripting
Answer

Depending on the Scripting language that you are using there are two different approaches:

1) Python:

Here you just have to prepare a Python list of values and assign it to a parameter of interest. Parameter size will adopt automatically to size of the list

For Example:

typHmCcur.kbal=[6,8,10]

typHmCcur.cbal_phase=[120,180,50]

 

2) DPL:

 

To resize and assign values to tabular parameter use of SetSize() and SetVal() methods  is needed.

 

harmSource.SetSize('kbal',3);

 

harmSource.SetVal(6,'kbal',1);

harmSource.SetVal(8,'kbal',2);

harmSource.SetVal(10,'kbal',3);

 

harmSource.SetVal(120,'kbal',1);

harmSource.SetVal(180,'kbal',2);

harmSource.SetVal(50,'kbal',3);

 

Back