Expand my Community achievements bar.

SOLVED

Adaptive form calculate expression for multiple instances

Avatar

Level 1

How do you call each instance and get the numeric value to calculate a total value? I'm stuck at identifying the syntax for each instance's value - here's the script for the calculated field:

 

var f = guideRootPanel.tblAgencies.Agency.instanceManager.instanceCount;
var total = 0;
for (var i=0; i < f; i++) {
total = total + guideRootPanel.tblAgencies.Agency(i).ContractID.value;
}
this.value = total;

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Level 1

Our team found the answer in case this helps someone else:

 

total = total + Agency.instanceManager.instances[i].ContractID.value;

View solution in original post

2 Replies

Avatar

Correct answer by
Level 1

Our team found the answer in case this helps someone else:

 

total = total + Agency.instanceManager.instances[i].ContractID.value;

Avatar

Employee Advisor

@SiriKK  We will get this documented.