Entering content frame

Background documentationWorking With the ALV Grid Control Locate the document in its SAP Library structure

Basics

The following graphic illustrates the steps required to display a list with the ALV Grid Control:

This graphic is explained in the accompanying text

As a minimum, you must provide the following two types of information for displaying the data:

Generally, the output table contains data that you previously selected from database tables.

Caution

The reference to the output table that you pass to the ALV Grid Control should be valid as long as the ALV Grid Control operates on it. Besides defining this reference as a global table, you can also hold the reference in an ABAP Objects instance using a public attribute.

The field catalog is a table that contains information on the fields to be displayed. For example, the ALV uses this table to identify the type of a field. You can also use special fields of this catalog to determine the number format and column properties of the list to be output.

Working With Controls

As a result of using ABAP Objects for Release 4.6A, SAP made controls programming consistent for the following procedures:

For Basis controls (such as the textedit control, the HTML viewer control or the picture control), the same programming model is applicable to the above procedures.

This programming model is also valid for the ALV Grid Control, with some restrictions, however, in the area of event handling (see next section). To make yourself familiar with this general model, see Structure link Creating a Control (and all cross-references). Also, you are absolutely recommended to read the next section on the special aspects of the ALV Grid Control.

Special Event Handling Aspects of the ALV Grid Control

The ALV Grid Control uses the grid control to display the output table. So we can say that the ALV Grid Control is a wrapper that uses the wrapper of a Basis control. As the 'outer layer', this wrapper spares the developer from having to register the events on the frontend in order to simplify event handling. The ALV Grid Control differs from Basis controls in the following respects:

Note

If you want to register all events as application events, you must use parameter I_APPL_EVENTS ( See also: CONSTRUCTOR). As usual, you must then call method CL_GUI_CFW=>DISPATCH in the PAI module.

 

 

 

 

 

 

 

Leaving content frame