‎2007 May 04 10:01 AM
Hello,
I have an ALV grid with totals & subtotals. I would like to insert an additional line below the subtotals line, with extra information from another table. Is this possible? Is there a way to do this without using the old WRITE statement?
‎2007 May 04 10:03 AM
Hi
Use End-of-Page event of ALVs.
That can help u.
Regards,
Sreeram
‎2007 May 04 10:05 AM
Yes you can do this,
And there is no need of write statement in ALV .. .it will not get your statement that you have written in write..
Write statement is only for simple report programming.
For ALV you have to build a fieldcatalog and then use LIST or GRID display to disply the final table ...
Yes You can write additional information in 'TEXT' field of the fieldcatalog.
Regards,
Jayant
‎2007 May 04 10:07 AM
Hi Popescu,
U can only pass one table in fun
"REUSE_ALV_GRID_DISPLAY"
so put that extra information in this internal table .
use end-of-page event of ALV.
Use Fm "REUSE_ALV_EVENTS_GET"
Reward points if helpful.
Regards,
Hemant
‎2007 May 04 10:42 AM
An example would be very usefull.
I don't know if i explained very well what I want.
Let's say that my ALV looks like this:
Field 1 a b c
Field 1 a b c
Field 1 a b c
Subtotal for Field 1 sum(a) sum(b) sum(c)
*************************************
Here I need extra line
*************************************
Field 2 a b c
Field 2 a b c
...
Using end of page I don't think it would be usefull. Is it ?
‎2007 May 04 11:53 AM
Hi,
Why dont you..
At New field.
Append a blank line.
EndAt.
in your data tab..add a 4 lenght field
color(4)...
for all the blank lines
pass 'CXYZ'.
where X is the color..
in that way you can get a blank line which is colorful after the records..
santhosh
‎2007 May 04 3:04 PM
hi Santosh,
thank you for your answer can you be more spcific
like where we need to add the below code for the blank line in ALV after sub totals
the color(4)...
for all the blank lines
pass 'CXYZ'.
‎2007 May 04 3:16 PM
have never tried this but give a try...
chk the events AFTER_LINE_OUTPUT and BEFORE_LINE_OUTPUT in it_events