>What I am trying to accomplish is when the user checks the subtotal field on the ASSET TOTAL line item, the system will calculate upwards until it hits Beginning of File (if first group) or until it hits the first 0 code line item (i.e ORDER #6 thru 5)
LNTOTAL=0
LNCURRECORD=RECNO()
DO WHILE !BOF() AND CODE!=0
LNTOTAL=LNTOTAL+CODE
SKIP -1
ENDDO
GOTO LNCURRECORD
>However, if the user only checks the GRANDTOT checkbox on line item 7, the system will calculate everything until the beginning of the file.
CALCULATE SUM(CODE)