Application Development 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: 

writing some text and inserting some variables in subtotals filed

Former Member
0 Kudos

Hi,

I have to write some text and insert some variables in subtotals fields using CL_SALV_TABLE method...

how to do that?

i have to give a subtotal field as:

Subtotal for : Variable1 Variable2 Records. 1043543(subtotal).

i have done the subtotal part but unable to implement this??

please help me..

Reward points if useful..

11 REPLIES 11

former_member210123
Active Participant
0 Kudos

ALV Layout there is a field called 'subtotals_text'.

e.g. is_layout-subtotals_text = 'Test'.

The subtotal text will be test.

Former Member
0 Kudos

Hi,

Check this code.


concatenate text variable1 variable2 into subtotal.

where variable1 and variable2 are the variables which you are enterin in the subtotal field and 'text' is the text which u want.

Reward if helpful.

Regards.

0 Kudos

How eill we display it after concatenating it

..

0 Kudos

Hi,

Check this code.


write : / subtotal

Thats it.. in case you are still facin some problem.. let me know...

Reward if helpful.

Regards.

0 Kudos

This ia ALV using OOP's .. we can't use write statement here...

0 Kudos

Hi,

Ok..then how do you usually display the fields in alv oops..

Regards.

0 Kudos

DIsplay it by using method's .. it's very complex if u dont know. it can't be done according to me

0 Kudos

Hi,

well,

Just have subtotal field declared as a string and then write this using oo alv just as you know.

Concatenating the field , should not affect they way you display the output.

Reward if helpful.

Regards.

0 Kudos

it can't be done this way.. i tried it

0 Kudos

Hi,

Sorry buddy,

I dont think i can help you more than this. I dont know much about oo abap.

Regards.

0 Kudos

thanks fr ur reply.. gud try