Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

I want to add custom screen in a select-options ?

Former Member
0 Kudos

Hi all ;

I want to add select-options code in my custom screen. I cant do that text options and how can I do this ?

Regards

İrfan;

1 ACCEPTED SOLUTION

Former Member
0 Kudos

SELECTION-SCREEN COMMENT /1(45) text-023.

u can use this statement to write a text message in your custom screen. /1(45) - it is nothing but a length to where the message will display.

if u want to add a tittle to ur custom screen follow the code.

give the title in text element.

SELECTION-SCREEN: BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.

SELECT-OPTIONS : S_BUKRS FOR BSIS-BUKRS NO-EXTENSION OBLIGATORY,

S_PRCTR FOR BSIS-PRCTR OBLIGATORY,

S_RACCT FOR BSIS-HKONT NO-DISPLAY,

S_YEAR FOR BSIS-GJAHR NO-EXTENSION NO INTERVALS OBLIGATORY DEFAULT SY-DATUM+0(4),

S_DATE FOR BSIS-AUGDT NO-EXTENSION NO INTERVALS OBLIGATORY DEFAULT SY-DATUM,

S_PERIOD FOR BSIS-MONAT NO-DISPLAY.

SELECTION-SCREEN: END OF BLOCK B1.

8 REPLIES 8

former_member212653
Active Contributor
0 Kudos

Check out this link on how to create a select-option in a screen.

http://abap-explorer.blogspot.com/2008/08/create-select-options-in-module-pool.html

Former Member
0 Kudos

Hi,

Selection-Screen Begin of screen 250 as sub-screen.

select-options: S_XYZ for ABC-XYZ.

selection-screen: end of screen 250.

in the custome screen create a subscreen area.

and

in PBO

Call subscreen SUBSCREENA Including Sy-Repid 250.

PAI

Call subscreen SUBSCREENA

santhosh

Former Member
0 Kudos

SELECTION-SCREEN COMMENT /1(45) text-023.

u can use this statement to write a text message in your custom screen. /1(45) - it is nothing but a length to where the message will display.

if u want to add a tittle to ur custom screen follow the code.

give the title in text element.

SELECTION-SCREEN: BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.

SELECT-OPTIONS : S_BUKRS FOR BSIS-BUKRS NO-EXTENSION OBLIGATORY,

S_PRCTR FOR BSIS-PRCTR OBLIGATORY,

S_RACCT FOR BSIS-HKONT NO-DISPLAY,

S_YEAR FOR BSIS-GJAHR NO-EXTENSION NO INTERVALS OBLIGATORY DEFAULT SY-DATUM+0(4),

S_DATE FOR BSIS-AUGDT NO-EXTENSION NO INTERVALS OBLIGATORY DEFAULT SY-DATUM,

S_PERIOD FOR BSIS-MONAT NO-DISPLAY.

SELECTION-SCREEN: END OF BLOCK B1.

0 Kudos

First ; thanks to answers ,

I m try this codes and Im write this code ;

  REPORT  Y_IRFAN_TEST_SUBSCREEN.

tables:mara.

 SELECTION-SCREEN BEGIN OF SCREEN 050 AS SUBSCREEN.

       select-options s_matnr for mara-matnr.

 SELECTION-SCREEN END OF SCREEN 050.

 START-OF-SELECTION.

 call SCREEN 100.

PBO in a screen 100

   

PROCESS BEFORE OUTPUT.
 MODULE STATUS_0100.
  CALL subscreen AREA1 including sy-repid
         050.
PROCESS AFTER INPUT.
 MODULE USER_COMMAND_0100.

I create AREA1 subscreen container in a screen 100. But I cant activate my program. An error occured.

What wrong this code ?

Regards

İrfan

0 Kudos

Nobody know this ?

Error is :

"Error when generating the selection screen "0050" of report"

Edited by: Irfan MATAK on Sep 20, 2008 7:58 AM

0 Kudos

Hi

Refer the demo program DEMO_DYNPRO_SUBSCREENS.

[Click here|http://help.sap.com/saphelp_nw04/Helpdata/EN/9f/dbabfe35c111d1829f0000e829fbfe/content.htm]

You have to call subscreen in PAI as well.

0 Kudos

Thanks Asik ;

Yes , my pai decleration is missing ! Problem is solved.

Regards.

0 Kudos

Last Question ;

I can run subscreen in the my main screen but ; How am I use subscreen to selection screen.

I use this code but an error.


 SELECTION-SCREEN: BEGIN OF SCREEN 0050 AS SUBSCREEN NO INTERVALS.
       select-options s_matnr for mara-matnr.
 SELECTION-SCREEN: END OF SCREEN 0050.

how this is possible.