Table controls are created on the screen using the tool Screen Painter. You can define as many table controls as you require for each screen.
First a table control area is created, into which the table control fields are then transferred.
Defining the Table Control Area
The table control area is created on the screen using the Screen Painter tool. The table control area is a multi-line screen element of a particular size, which must be assigned a name. The name identifies the table control and is used in screen flow logic and in ABAP programs to address it.
A table control has a few other special attributes apart from its name and size.
The size of a table control can be fixed or changeable. The size of a table control changes when a user changes the size of a window, thereby cutting off a part of the table. The size change triggers the PAI event.
The top line of a table control can be reserved as a title line, into which a text field or an output field can be inserted.
The second line of a table control can be reserved as a title line, where a text field or output field can be inserted in each column. At the same time the column titles function as buttons to select columns.
The user can save the current settings of the attributes in a file. The system uses these settings every time the table control is displayed.
Horizontal and vertical separators can be displayed between lines and columns.
You can specify whether lines can be selected, and if so how many.
You can specify whether columns can be selected, and if so how many.
A column of the table control can be reserved as buttons for marking lines, it is treated internally as a checkbox. A selected line selection button contains X, an unselected one contains ' '. The selection column must be assigned a name. The state of the selection button can be transported into a character field, with length one and the same name, in an ABAP program and vice versa.
A number of columns (from the left) can be excluded from the scrolling function. A fixed column cannot be moved.
The Table Control Field
After a table control area has been created on the screen, the following single-line screen elements can be transferred into the area.
Radio Button Elements
Text fields and output fields can be transferred to the title lines.
The screen elements, frames, subscreens, tab strips, custom controls and status icons can not be transported to the table controls.
You can also transfer dictionary and program fields. When fields are transferred from the ABAP Dictionary, it is possible that column headers will be automatically assigned a text from the data element from the Dictionary.
Every screen element that is inserted makes up a column of the table control. In every free line available, under any title and column headers, the screen element is displayed repeatedly.
The screen elements of a column appear only once in the element list of the corresponding screen. Therefore, you only have to create fields with the same name once in ABAP programs.