>Terry,
>
>I'm using automation.
The cells in the column could be summed during the loop that writes the VFP values to the Excel sheet.
lnTotal=0
lnCellRow=3
scan
.Cells(lnCellRow,lnColOffSet).Value=mydbf.myField
lnTotal=lnTotal+mydbf.myField
lnCellRow=lnCellRow+1
endscan
The syntax "formulaR1C1" is how the recorded [Excel] macro designated the rows on the excel spreadsheet that were to be totaled.
I've never used it:)! My automation efforts total colums similar to the example in this post.
If a copy to XLS or a DataToCLip method was used to get the data to the worksheet, the then Excel SUM() function might be the way to go. The syntax posted was made available by the excel macro recorder when [I] applied the SUM() function on the worksheet.
>
>Can you explain the syntax of the formulaR1C1?
Imagination is more important than knowledge