In your field catalog u can use do_sum automatically the sum will be calculated.
In which column u need sum u just use the below code..
don't use for description column , only use for amount column.
wa_fieldcat-fieldname = 'LOCCURAM'.
wa_fieldcat-seltext_m = 'Price'.
*Calculate Total for Price
wa_fieldcat-do_sum = 'X'.
APPEND wa_fieldcat TO it_fieldcat.
