Checkbox followed by itab-field
Pls me on this. I want to show the data from itab which each line lead by checkbox.
As above, i want user to tick the line they want then collect the selected line into itab.
in this case, please help me how to put the checkbox in front of each line. and please advise me how to modify the table after user selects the rows already.
Thanks in advance,
Following code will display records with the checkboxes, you can select particular record and display it or store into another table then process further for collect.
DATA: date TYPE d,
flag(1) TYPE c,
wa(10) TYPE c.
date = sy-datum.
DO 10 TIMES.
date = date + sy-index.
WRITE: / flag AS CHECKBOX, (10) date.
READ LINE sy-index FIELD VALUE flag
date INTO wa.
IF sy-subrc <> 0.
ELSEIF flag = 'X'.
WRITE / wa.