Application Development and Automation 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: 
Read only

List Viewer

Former Member
0 Likes
766

Experts,

Is there an easy way to send an internal table to output to a list viewer? Any documentation, suggestions, or code samples are appreciated....Thanks!

6 REPLIES 6
Read only

Former Member
Read only

Former Member
0 Likes
741

Tom,

Please find the below documentation for the ABAP list viewer.

FU REUSE_ALV_LIST_DISPLAY

____________________________________________________

Text

Output a simple list (single line or several lines)

Functionality

This module outputs an internal table with any structure as a formatted

one-line or multiple-line list.

Principle:

o Pass an internal table with the set of output information

o Pass a structure with general list layout details

o Pass a field catalog as an internal table

The field catalog describes the fields to be output in the list.

Notes

o All actions on the list refer directly to the internal output table,

e.g. sorting the list also sorts the passed internal output table

(passed by reference).

o An important consideration for the use of the tools and certain

generic functions (totals, subtotals) is the expected amount of data

to be displayed.

The application must take this consideration into account.

Thanks,

Read only

Former Member
Read only

Former Member
0 Likes
741
Read only

Former Member
0 Likes
741

Hi,

check SAP DEMO program : BCALV_TEST_LIST_EVENTS

rgds,

latheesh

Read only

Former Member
0 Likes
741

Hi Tom,

You can make use of two alv function modules

TYPE-POOLS: SLIS.

data <filedcatalog name> type SLIS_T_FIELDCAT_ALV.

CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'

EXPORTING

I_PROGRAM_NAME = <prog name(sy-repid)>

I_INTERNAL_TABNAME = <'int tabname'>"caps!

I_INCLNAME = <prog name(sy-repid)>

CHANGING

CT_FIELDCAT = <filedcatalog name>

EXCEPTIONS

INCONSISTENT_INTERFACE = 1

PROGRAM_ERROR = 2

OTHERS = 3.

CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'

EXPORTING

I_CALLBACK_PROGRAM = <prog name(sy-repid)>

IT_FIELDCAT = <filedcatalog name>

I_SAVE = 'A'

TABLES

T_OUTTAB = <Int Tabname>

EXCEPTIONS

PROGRAM_ERROR = 1

OTHERS = 2.