>OK, I give. In a report I created a variable called lnSubtotal and in its value to store I put SUM(viewname.numericfieldname). I received a "'Sum.prg' does not exist". I tried other combinations such as SUM(viewname.numericfieldname) TO lnSubtotal, SUM viewname.numericfieldname, and CALCULATE SUM(viewname.numericfieldname).
>
>What is the correct syntax?
>
>Thanks
>JD
You do not use the VFP SUM function this way. Put a field control in the Group Footer or Summary band of the report with that field as the expression. Click the Calcualtions and check the Sum option.
Mark McCasland
Midlothian, TX USA