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: 

Difference between cl_gui_alv_grid and cl_salv_table...

manuelhildemaro_ramossanc
Active Participant
0 Kudos

Hi.. Good Day...

I'll like to know what is the difference of using cl_gui_alv_grid or

cl_salv_table... I'm using cl_gui_alv_grid, and it seems to me better, and much more complete..

However somebody know more precisely the advantages of using these classes ?

Thank 4 u comments..

Manuel H.

1 ACCEPTED SOLUTION

RichHeilman
Developer Advocate
Developer Advocate

Hi. The CL_SALV_TABLE class is part of the ALV Object Model which was introduced in NetWeaver 2004. Basically it is an encapsulation of the the pre-existing ALV tools. For example the class CL_SALV_TABLE actually wraps around both the CL_GUI_ALV_GRID class for container implementation, as well as the REUSE_ALV_GRID_DISPLAY and REUSE_ALV_LIST_DISPLAY function modules for full screen display. It was designed to be a single point of entry when using a specific ALV tool such as the ALV table display, ALV hierarchial sequestion list, and tree ALV. All of these individual ALV tools have their own base class, for table it is the CL_SALV_TABLE, but all have a common look. A lot of the methods are the same, with only some differences in the parameters of the methods depending on the actual tool you are using.

So to summarize, the ALV Object Model was delivered to give a more collective interface to the ALV tools. There are limitations in the ALV OBject Model, for example, you can NOT color a line or a cell, but you can color a column. Also, you can NOT have an editable ALV using the Object Model.

But for basic lists, it is a very powerful tool.

Regards,

Rich Heilman

3 REPLIES 3

RichHeilman
Developer Advocate
Developer Advocate

Hi. The CL_SALV_TABLE class is part of the ALV Object Model which was introduced in NetWeaver 2004. Basically it is an encapsulation of the the pre-existing ALV tools. For example the class CL_SALV_TABLE actually wraps around both the CL_GUI_ALV_GRID class for container implementation, as well as the REUSE_ALV_GRID_DISPLAY and REUSE_ALV_LIST_DISPLAY function modules for full screen display. It was designed to be a single point of entry when using a specific ALV tool such as the ALV table display, ALV hierarchial sequestion list, and tree ALV. All of these individual ALV tools have their own base class, for table it is the CL_SALV_TABLE, but all have a common look. A lot of the methods are the same, with only some differences in the parameters of the methods depending on the actual tool you are using.

So to summarize, the ALV Object Model was delivered to give a more collective interface to the ALV tools. There are limitations in the ALV OBject Model, for example, you can NOT color a line or a cell, but you can color a column. Also, you can NOT have an editable ALV using the Object Model.

But for basic lists, it is a very powerful tool.

Regards,

Rich Heilman

0 Kudos

Thanks to Rich and Yash.

Very util your information. I'll begin to analyse it.

former_member188685
Active Contributor
0 Kudos

cl_salv_table is advamced than cl_gui_alv_grid .

you will have some extra functionalities in cl_salv_table

Check this Document.

https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/eac1fa0b-0e01-0010-0990-8530de49...