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: 

Hierarchical list with multiple levels - separate attributes on all level

former_member283411
Participant
0 Kudos

Hello Everyone,

I would like to create a hierarchical ALV list, like the BCALV_TREE_01 program. But my problem with this program is that you can display attributes of the record (as plane type, capacity, total costs,etc.) on the lowest level only. So this is just a nice grouping possibity. My aim would be to have attributes even on the first level of hierarchy, which could be different from the attributes of the lower lever hierarchies.

This is how the demo looks like:

As you can see, I don't have any values in the row of "2016 March", or in the row of "JL" (or even if I have values there, those are just sums of the lower level values). For example in my report the "2016 March" should have a price 100, the DL row should have price 200, and JL should have price 10000. I would need to print completely different attributes on each level. Is that possible somehow?


Many thanks in advance.

Tamas

1 ACCEPTED SOLUTION

gabmarian
Active Contributor
0 Kudos

If you take a closer look on the program you can see that structure ls_slfight passed for parameter is_outtab_line is empty everywhere except at leaf level of the structure.

E.g. If you assign values (via debug) to the fields of ls_sflight in subroutine add_month the values will be displayed on the screen.

BR,

Gabor

2 REPLIES 2

gabmarian
Active Contributor
0 Kudos

If you take a closer look on the program you can see that structure ls_slfight passed for parameter is_outtab_line is empty everywhere except at leaf level of the structure.

E.g. If you assign values (via debug) to the fields of ls_sflight in subroutine add_month the values will be displayed on the screen.

BR,

Gabor

0 Kudos

Hi Gabor,

thank you very much, it works!

Thanks,

Tamas