Code: Alles auswählen.
FUNCTION zisu_zmetmethod.
*"----------------------------------------------------------------------
*"*"Lokale Schnittstelle:
*" IMPORTING
*" VALUE(Y_ANLAGE) LIKE EANL-ANLAGE
*" EXPORTING
*" VALUE(YT_ZMETMETHOD) LIKE ZMETMETHOD STRUCTURE ZMETMETHOD
*"----------------------------------------------------------------------
DATA: wa_zmetmethod LIKE zmetmethod.
DATA: start_column TYPE i VALUE 25,
end_column TYPE i VALUE 120,
start_row TYPE i VALUE 6,
end_row TYPE i VALUE 15.
* Beispiel:
SELECT * FROM zmetmethod
INTO TABLE it_zmetmethod
WHERE anlage = y_anlage.
CALL SCREEN 0505 STARTING AT start_column start_row
ENDING AT end_column end_row.
ENDFUNCTION.
Code: Alles auswählen.
PROCESS BEFORE OUTPUT.
MODULE STATUS_0505.
LOOP AT it_zmetmethod
INTO dyn_zmetmethod
WITH CONTROL zz_control.
ENDLOOP.
Code: Alles auswählen.
PROCESS AFTER INPUT.
LOOP AT it_zmetmethod.
MODULE read_table_control.
ENDLOOP.
MODULE USER_COMMAND_0505.
Code: Alles auswählen.
MODIFY it_zmetmethod FROM dyn_zmetmethod
INDEX zz_control-current_line.
ENDMODULE.
Code: Alles auswählen.
IF ...leere Zeile in Datentabelle ....
LOOP AT zz_control-cols INTO wa_control_cols.
LOOP AT wa_control_cols-screen.
IF wa_control_cols-screen-group1 = 'MOD'.
wa_control_cols-screen-input = '1'.
modify wa_control_cols-screen.
ENDIF.
ENDLOOP.
ENDLOOP.
ENDIF.
Code: Alles auswählen.
MODULE modify_screen OUTPUT.
DATA: l_lines TYPE sy-tabix.
DESCRIBE TABLE it_zmetmethod LINES l_lines.
LOOP AT SCREEN.
IF zz_control-current_line = l_lines.
IF screen-name = 'DYN_ZMETMETHOD-AB' OR
screen-name = 'DYN_ZMETMETHOD-ZZMETMETHOD'.
screen-input = 1.
MODIFY SCREEN.
ENDIF.
ENDIF.
ENDLOOP.