- Mark as New
- Follow
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report
Hi,
as the GoalSheet is a repeatable instance as the Others row you have to loop through all its instanced too.
var goalSheets = _GoalSheet.count,
sum = 0;
for (var i = 0; i < goalSheets; i += 1) {
var vGoalSheet = form1.resolveNode("GoalSheet[" + i + "]"),
vOthers = vGoalSheet.Table6._Others.count;
if (vGoalSheet.Table6.First.Funding1.rawValue == "1") {
sum += vGoalSheet.Table6.First.Funding1.rawValue;
for (var j = 0; j < vOthers; j += 1) {
sum += vGoalSheet.Table6.resolveNode("Others[" + j + "]").Cost2.rawValue;
}
}
}
this.rawValue = sum;
Hope this helps.
Views
Replies
0 Likes
Total Likes