01-20-2016 7:29 AM
Hello,
Using below thread I am able to get total and subtotal at the ALV output.
But my requirement is to display subtotal at the end of the output. Due to above code I am not getting subtotal at the end.
Below is the scenario :
First 4 lines are ALV output :
Expected output :
Amount | Currency |
---|---|
150 | USD |
200 | EUR |
100 | EUR |
250 | USD |
Subtotal : 300 | EUR |
Subtotal : 400 | USD |
Current Output :
Header 1 | Header 2 |
---|---|
150 | USD |
250 | USD |
Subtotal : 400 | USD |
100 | EUR |
200 | EUR |
Subtotal : 300 | EUR |
Please help in this regard.
Thanks in advance.
01-20-2016 8:42 AM
Hi,
Use cl_salv_column_table set_currency_column .
See program SALV_TEST_TABLE_STRUCTURE .
Regards
01-20-2016 7:43 AM
If you defined correctlty the amount field, i.e. you linked the field to the currency field in the field catalog. Then you are no longer required to define a sort/sub total on field currency, but the grand total will consist of one line per currency code.
Regards,
Raymond
01-20-2016 7:49 AM
Thanks for your reply.
your comment is valid if i am using REUSE_ALV but in my case I am using CL_SALV so I am not using field catalog.
If we can link that in CL_SALV also without creating field catalog then please let me know.
Please let me know in case of concerns.
Regards,
Onkar
01-20-2016 8:42 AM
Hi,
Use cl_salv_column_table set_currency_column .
See program SALV_TEST_TABLE_STRUCTURE .
Regards
01-20-2016 10:52 AM