Skip to Content
0
Former Member
Jan 17, 2008 at 11:43 AM

Selection-screen in subroutine

261 Views

Hi,

I would like to know if I can create my selection-screen using a subroutine.

Here is my selection-screen.

SELECTION-SCREEN : BEGIN OF LINE, COMMENT 1(45) text-aaa, POSITION 50.
PARAMETERS : p_aaa  TYPE rcgfiletr-ftappl OBLIGATORY.
SELECTION-SCREEN END OF LINE.

SELECTION-SCREEN : BEGIN OF LINE, COMMENT 1(45) text-bbb, POSITION 50.
PARAMETERS : p_bbb  TYPE rcgfiletr-ftappl OBLIGATORY.
SELECTION-SCREEN END OF LINE.

SELECTION-SCREEN : BEGIN OF LINE, COMMENT 1(45) text-ccc, POSITION 50.
PARAMETERS : p_ccc  TYPE rcgfiletr-ftappl OBLIGATORY.
SELECTION-SCREEN END OF LINE.

I tried this but it doesn't work.

PERFORM test : USING text-aaa p_aaa,
                          USING text-bbb p_bbb,
                          USING text-ccc p_ccc.

FORM test USING text parameter.
SELECTION-SCREEN : BEGIN OF LINE, COMMENT 1(45) text, POSITION 50.
PARAMETERS : parameter  TYPE rcgfiletr-ftappl OBLIGATORY.
SELECTION-SCREEN END OF LINE.
ENDFORM.

Error message : SELECTION-SCREEN statement is not allowed in FORM

Has anyone got an idea ?

Regards