Hello everyone, this is my first blog, i would like to share with you a multi ALV display code repository written by me.
Introduction
I am an ABAP developer who is willing to share. This blog will introduce an open source repository that I have written. It can display multiple ALVs on a single screen with a few simple lines of code, with a Tabtrips style horizontal and vertical layout. Its underlying implementation is based on the BUS Screen Framework. If you are interested in this framework, you will learn how to use it
System version requirements
SAP ON PREMISE
ABAP 750 and later versions
Target Users
ABAP developer
If you want to display multiple ALVs on one screen and only need to write a little code, it can save you a lot of time.
Of course, it also allows you to display only one ALV, just by passing in a line item to
IT_ALVS parameter.
Technical implementation
- FALV
- BUS-Screen Framework
Falv is a awesome project and I used it in my project . It can reduce my code volume and improve efficiency
How to use
It is very simple to use, as shown in the following code:
SELECT * FROM usr21 INTO TABLE @DATA(lt_usr21) UP TO 100 ROWS.
SELECT * FROM adrc INTO TABLE @DATA(lt_adrc) UP TO 100 ROWS.
SELECT * FROM kna1 INTO TABLE @DATA(lt_kna1) UP TO 100 ROWS.
NEW zcl_alv_multi( iv_mode = zcl_alv_multi=>alv_mode-horizontal
iv_title = 'MULTI ALV DEMO01'
it_alvs = VALUE #(
( title = 'USR21' table = REF #( lt_usr21 ) )
( title = 'ADRC' table = REF #( lt_adrc ) )
( title = 'KNA1' table = REF #( lt_kna1 ) )
) )->display( ).
You can find more demos in my code repository
Screenshot
1.horizontal layout: tabstrip style
Figure 1: "horizontal layout& selected tab1"
Figure 2: "horizontal layout& selected tab3"
2.vertical layout
Figure 3: "vertical layout"
Code repository
Github:
https://github.com/a87b01c14/MULTI_ALV.git
Reference link
FALV: https://github.com/fidley/falv
BUS Screen Framework related blogs:
BUS-Screen Framework – A short introduction by
tudor.riscutia
BUS Screen Framework – Working with Tabstrips by
31a8856c1f6f4bcfa7f3d890a0b88fd2
If you have any questions, please comment under the blog and I will reply as soon as possible.