Avatar

Level 2

You might be able to use this since I've simplified it a bit from what we use.  We have a field called 'policyType' wrapped in a subform called 'subOtherInsuranceDetail'.  This subform is wrapped in a subform called 'subOtherInsuranceList'.  We need to find the number of instances of 'policyType' that contain a string 'aString'.


var otherDetailLines = subOtherInsuranceList.resolveNodes("subOtherInsuranceDetail[*]");

for (i = 0; i < otherDetailLines.length; i++)
    {
    if (otherDetailLines.item(i).resolveNode("policyType").rawValue != "aString")
            {
                otherUncompleteRows = otherUncompleteRows + 1;
            }
    }