Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

urgent: displaying currency (i.e INR,ISK etc) beside grand total

Former Member
0 Kudos
118

hi pelluka and hi to all,

hi to all,

i developed an alv report in that there is an amount field and i sum up all the amounts and make that grand total.<b>Along with grand total i want to display the particular currency i.e ISK,INR etc beside the same grand total field.</b> like ISK 900.can any one help me in this regard.

eg: 100

200

-


<b>INR 300</b>

this is the requirement i want.

thanks

raj

1 ACCEPTED SOLUTION

LucianoBentiveg
Active Contributor
0 Kudos
80

You need an extra column with currency becose amounts could be in more than one currency. Add currency column to ALV itab, and in field catalog for amount quantity add CFIELDNAME = 'ITAB-CURRCOL'. By this way totals are displayed by currency.

Example:

gt_fieldcat-seltext_l = 'Currency'.

gt_fieldcat-fieldname = 'WAERS'.

gt_fieldcat-just = 'C'.

gt_fieldcat-outputlen = '13'.

gt_fieldcat-tabname = 'T_OUTPUT'.

APPEND gt_fieldcat. CLEAR gt_fieldcat.

gt_fieldcat-seltext_l = 'Amount'.

gt_fieldcat-cfieldname = 'WAERS'.

gt_fieldcat-fieldname = 'WRBTR'.

gt_fieldcat-just = 'R'.

gt_fieldcat-outputlen = '16'.

gt_fieldcat-tabname = 'T_OUTPUT'.

APPEND gt_fieldcat. CLEAR gt_fieldcat.

Regards

P.D.: Please Don't open more threads with this issue. (there is three now)

1 REPLY 1

LucianoBentiveg
Active Contributor
0 Kudos
81

You need an extra column with currency becose amounts could be in more than one currency. Add currency column to ALV itab, and in field catalog for amount quantity add CFIELDNAME = 'ITAB-CURRCOL'. By this way totals are displayed by currency.

Example:

gt_fieldcat-seltext_l = 'Currency'.

gt_fieldcat-fieldname = 'WAERS'.

gt_fieldcat-just = 'C'.

gt_fieldcat-outputlen = '13'.

gt_fieldcat-tabname = 'T_OUTPUT'.

APPEND gt_fieldcat. CLEAR gt_fieldcat.

gt_fieldcat-seltext_l = 'Amount'.

gt_fieldcat-cfieldname = 'WAERS'.

gt_fieldcat-fieldname = 'WRBTR'.

gt_fieldcat-just = 'R'.

gt_fieldcat-outputlen = '16'.

gt_fieldcat-tabname = 'T_OUTPUT'.

APPEND gt_fieldcat. CLEAR gt_fieldcat.

Regards

P.D.: Please Don't open more threads with this issue. (there is three now)