Error in calling a selection-screen...

Hello experts,
Please look at my code below:
SELECTION-SCREEN BEGIN OF SCREEN 500 AS WINDOW.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_upld RADIOBUTTON GROUP grp2.
SELECTION-SCREEN COMMENT 2(20) text-007 FOR FIELD pr_upld.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 03(15) text-a11 FOR FIELD p_flnme.
PARAMETERS: p_flnme LIKE rlgrap-filename DEFAULT 'C:'.
SELECTION-SCREEN END OF LINE.
PARAMETERS: pr_list1 RADIOBUTTON GROUP grp2.
SELECTION-SCREEN COMMENT 2(7) text-003 FOR FIELD pr_list1.
SELECTION-SCREEN END OF SCREEN 500.
SELECTION-SCREEN BEGIN OF SCREEN 1500 AS WINDOW.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(22) text-002 FOR FIELD p_dcode.
PARAMETERS: p_dcode LIKE vbak-kunnr,
            p_name1 LIKE kna1-name1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_list2 RADIOBUTTON GROUP grp.
SELECTION-SCREEN COMMENT 2(7) text-003 FOR FIELD pr_list2.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_add  RADIOBUTTON GROUP grp.
SELECTION-SCREEN COMMENT 2(3) text-005 FOR FIELD pr_add.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_edit RADIOBUTTON GROUP grp.
SELECTION-SCREEN COMMENT 2(4) text-006 FOR FIELD pr_edit.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 03(20) text-a12 FOR FIELD p_code.
PARAMETERS: p_code LIKE zts0001-cdseq.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF SCREEN 1500.
IF v_compflag EQ space.
  CALL SELECTION-SCREEN 500.
ELSE.
  CALL SELECTION-SCREEN 1500.
ENDIF.
Now, what I want to do is that the program will call a selection-screen based on a given variable(v_compflag). But its generating an error saying that 'error generating the selection-screen'. Why is this so?
Again, thank you guys and take care!

Corrected code.
REPORT  ztest_errror                            .
data: v_compflag.
SELECTION-SCREEN BEGIN OF SCREEN 500 AS WINDOW.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_upld RADIOBUTTON GROUP grp2.
SELECTION-SCREEN COMMENT 2(20) text-007 FOR FIELD pr_upld
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 03(15) text-a11 FOR FIELD p_flnme.
PARAMETERS: p_flnme LIKE rlgrap-filename DEFAULT 'C:'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_list1 RADIOBUTTON GROUP grp2.
SELECTION-SCREEN COMMENT 2(7) text-003 FOR FIELD pr_list1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF SCREEN 500.
*************SELECTION-SCREEN BEGIN OF SCREEN 1500 AS WINDOW.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(22) text-002 FOR FIELD p_dcode.
PARAMETERS: p_dcode LIKE vbak-kunnr,
          p_name1 LIKE kna1-name1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_list2 RADIOBUTTON GROUP grp.
SELECTION-SCREEN COMMENT 2(7) text-003 FOR FIELD pr_list2.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_add  RADIOBUTTON GROUP grp.
SELECTION-SCREEN COMMENT 2(3) text-005 FOR FIELD pr_add.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_edit RADIOBUTTON GROUP grp.
SELECTION-SCREEN COMMENT 2(4) text-006 FOR FIELD pr_edit.
SELECTION-SCREEN END OF LINE.
*************SELECTION-SCREEN END OF SCREEN 1500.
IF v_compflag EQ space.
  CALL SELECTION-SCREEN 500.
ELSE.
  CALL SELECTION-SCREEN 1500.
ENDIF.
Regards
vijay

Similar Messages

  • Error message at the selection screen while processing screen logic

    Hi All,
      I need to show error message at the selection screen.
    I am calling the screen inside the START-OF-SELECTION, and processing the calculation and putting the data into i_final internal table. If internal table I_FINAL is empty I have to show error message saying ' DATA is empty' , this error message should be shown at the SELECTION SCREEN (Report input screen 1000) and provide the user to enter the input values once again.
    But whenever I am populating error message, I am getting a pop up to chose exit, and process is terminating.
    Since I am in the middle of the screen processing whenever I am giving a error message.
    Please let me know how can I populate error message without terminating the process while I was in the middle of the screen processing logic.
    Regards,
    Mahesh

    hi
    If u are trying to validate a field use
    AT SELECTION_SCREEN ON <field>
    if want to validate a block
    AT SELECTION SCREEN ON <block>
    If Universal Validation
    AT SELECTION SCREEN
    and display a 'E' Message inside the block.
    You can Enter Correct Value and start processing Forward.
    hope this will help.
    Regards
    Sumit Agarwal

  • Displaying error message while entering selection screen fields

    Moderator message: don't offer points
    hi experts...
    i generated a report.
    in that report, the selection screen fields are plant and material type..
    now my rqmt  is like this :
    if user enters any plant except '8210' in  the selection screen, then a pop up should appear like.. enter 8210 plant only, and the cursor should remain in the same screen allowing user to enter correct plant.
    and then same with the case of material type also..user should enter 'mcfe' material type only..
    im using message classes like this:
    if so_bwkey-low ne '8210' or so_bwkey-high ne '8210'.
      message i000(zts).
      endif.
    if so_mtart-low is not initial and so_mtart-high is not initial and so_mtart-low ne 'mcfe'
       or so_mtart-high ne 'mcfe'.
      message i001(zts).
      endif.
    with this logic, when i enter plant..it is prompting
    1) enter plant 8210 only..
    and then when i press enter key it is again prompting
    2)enter material type mcfe only..
    but iam not entering material type here..
    i want to get 2nd error message if and only if i enter material type..
    help me regarding this issue..
    <<text removed>>
    thanks in advance,
    harini.
    Edited by: Matt on Feb 9, 2009 10:14 AM

    Hi,
    Use Error type message in SELECTION SCREEN EVENT.It will place the cursor in the relevant Field.
    At SELECTION-SCREEN ON SO_BWKEY-Low.
    if so_bwkey-low ne '8210' .
    message E000(zts).
    endif.
    At SELECTION-SCREEN ON SO_BWKEY-HIGH.
    if  so_bwkey-high ne '8210'.
    message E000(zts).
    endif.
    At SELECTION-SCREEN ON so_mtart-LOW.
    if so_mtart-low is not initial and  so_mtart-low ne 'mcfe' .
    message E001(zts).
    endif.
    At SELECTION-SCREEN ON so_mtart-HIGH.
    if so_mtart-high is not initial 
    and so_mtart-high ne 'mcfe'.
    message E001(zts).
    endif.
    This will resolve the issue..
    Regards,
    Gurpreet

  • Calling userdefined selection screen

    Hi all,
    here i am having scenario like
    first calling a selection screen with push button, when click the button
    it should call anyother selection screen and execute that with selection parameters
    please let me know anyone

    Hii,
          first declare a pushbutton like ( if second selection parameter is date type)
    SELECTION-SCREEN PUSHBUTTON /05(20) c_date
                              USER-COMMAND cdate .
    SELECTION-SCREEN BEGIN OF SCREEN 0100." AS SUBSCREEN.
    SELECT-OPTIONS :       s_augdt FOR v_augdt OBLIGATORY NO-EXTENSION." no-display.
    SELECTION-SCREEN END OF SCREEN 0100.
    AT SELECTION-SCREEN.
    *----CHECK FOR USER COMMAND - CDATE MEANS USER HAS SELECTED CLEARIND DATE BUTTON FROM SELECTION SCREEN
      IF sy-ucomm = 'CDATE'.
    CALL SELECTION-SCREEN 0100 STARTING AT '10' '10' ENDING AT '120' '15'.
      ENDIF.
    Regards,
    Arti

  • Call report selection screen in module pool program with tab strip control

    Hi,
    Could anyone explain in detail to call report selection screen in module pool program with tab strip control.
    Thanks
    Mano

    Hi,
    Refer std program:
    demo_sel_screen_in_tabstrip.
    demo_sel_screen_with_tabstrip.
    Call your program with SUBMIT stmt form module program.
    Reward points if this Helps.
    Manish

  • Calling a selection screen in a subscreen of a tabstrip

    hi,
    I have created a tabstrip where i have included a subscreen.
    I want to create and call a selection screen within that subscreen.
    Can anybody tell me the steps required?
    thanks in advance,
    Abhishek

    hi
    good
    try this
    In the same way that you can define a screen as a subscreen in the Screen Painter, it is now possible to define selection screens as subscreens in an ABAP program:
    SELECTION-SCREEN BEGIN OF SCREEN scrn AS SUBSCREEN
                                         [NO INTERVALS]
                                         [NESTING LEVEL n].
    SELECTION-SCREEN END OF SCREEN scrn.
    go through this link
    http://help.sap.com/saphelp_nw2004s/helpdata/en/e7/deb237b9a9a968e10000009b38f8cf/content.htm
    http://sap.niraj.tripod.com/id40.html
    thanks
    mrutyun^

  • Calling the selection screen of the calling program after the execution of

    Hi all,
    I had created a program for a purchase order display.
    It has three radio-buttons from where i am calling different programs.
    I am using submit in the calling program and get parameter in at selection-screen output of the called program.
    I am getting the end report without the display of the selection screen of called program. But when i am clicking back on the end-report then i want to come back on the selection screen of the calling program. But i am coming out of the execution.
    Can anyone please tell me how to call the selection screen.
    Thanks in advance,
    Regards
    vamsi

    Hi, when you do the SUMBIT statement, make sure that you are using the extension........  AND RETURN.
    Submit <report> <b>AND RETURN</b>.
    This should return control to the caller.
    Regards,
    Rich Heilman

  • Can we call a selection screen from List output

    Hi Folks,
    Can we call a selection screen from the list output?
    I mean for ex:-
    i am getting the data from MAKT and displaying it in the list output having a button EMAIL.
    When I press that button it should call a selection screen asking the user to enter EMAIL id .
    Thanks,
    K.Kiran.

    Hi
    U can create a dynpro as SELECTION SCREEN and call it using CALL SELECTION-SCREEN statament:
    SELECTION-SCREEN BEGIN OF SCREEN 100.
    PARAMETERS: P_MAIL(80) TYPE C.
    SELECTION-SCREEN END    OF SCREEN  100.
    AT USER-COMMAND.
       CASE SY-UCOMM.
          WHEN 'MAIL'.
              CALL SELECTION-SCREEN 100.
              IF SY-SUBRC = 0. "User press F8
              ELSE.
                " User press exit or back
              ENDIF.
    U can use the addition STARTING AT ..... ENDING AT ..... if you need to show the selection-screen as popup
    Max

  • Calling a Selection Screen from a Function Module/Method

    Hi,
      I would like to call a selection screen from a function module or method. I understand it is not possible by the definition. Are there any alternative options as I am looking for the Variants Save option on the screen. Any thoughts?
    Thanks
    Raghav

    Since i don't know your exact requirements (standard SAP selection screen? your own selection screen?) the onl;y thing i can come up with is:
    1. in your function pool create your own screen with a subscreen area
    2. create your own selection screen as a subscreen.
    3. include the selection subscreen in the first screen
    4. call the first screen in your function.

  • 'Error when generating the selection screen "0500"

    Dear all,
    I have copied a function group QEES to ZQEES through SE80. In that I have copied all screens, includes, function modules etc..
    Now when I activate the ZQEES, I get an error 'Error when generating the selection screen "0500" of report "SAPLZQEES'.
    There is no problem with screen 0500, I have activated it.
    But when I activate ZQQES, I get the error.
    Please let me know the reason for this.
    It will be highly appr
    Thanks in advance,
    Sachin

    Hi Sachin,
    there could be a problem while copying in renaming, delete the Function group ZQEES  and recopy the  Standrad function group and only rename  the  the FM QEES_SHOW_SELECTION_SCREEN to ZQEES_SHOW_SELECTION_SCREEN and copy and activate it will work.
    regards,
    Srini

  • Error when generating the selection screen '0005'of report 'XYZ'

    Hi All,
       We copied std SAP pgm and were trying to rename the one of the screen but couldnt. When I tried to transport it to test system it went in to dump giving the error  Error when generating the selection screen '0005'of report 'XYZ' .
    Please advise me on how to remove this dump.
    Regards
    Saurabh

    If you look at the selection screen, you'll probably find that there are overlapping elements (text elements over select-options) or something like that.
    Rob

  • Error when Generating the Selection Screen?

    Hi Guys,
                   When i am executing the program with this code .I am getting this type of Error
    " Source code   ZUSFICOR00013_MM_ACNT_COSTING                Line     0
    Error when generating the selection screen "1000" of report
                 I got this Error while activating my program.The code which i wrote is the below one.
    SELECTION-SCREEN: BEGIN OF LINE.
    Select-Options : S_MATNR for MBEW-MATNR ."MatchCode Object MAT1,
    SELECTION-SCREEN COMMENT 2(10) TEXT-004 for field s_matnr.
    SELECTION-SCREEN: END OF LINE.
    Thanks,
    Gopi.

    Hi Seshu,
                  While doing EPC for the Below code
    SELECTION-SCREEN: BEGIN OF LINE.
    SELECTION-SCREEN COMMENT 2(15) TEXT-004 for field s_matnr.
    Select-Options : S_MATNR for MBEW-MATNR ."MatchCode Object MAT1,
    SELECTION-SCREEN: END OF LINE.
                  I am getting an Warning like " Selection text or parameter for selection field S_MATNR is not maintained"  How to coorect this one?
                   and also for the this Below Code
    s_fieldcatalog-col_pos = 1.
    s_fieldcatalog-fieldname = 'BWKEY'.
    s_fieldcatalog-tabname = 'i_MBEW_out'.
    s_fieldcatalog-seltext_l = 'Plant'.
    append s_fieldcatalog to t_fieldcatalog.
    clear s_fieldcatalog.
    s_fieldcatalog-col_pos = 2.
    s_fieldcatalog-fieldname = 'MATNR'.
    s_fieldcatalog-tabname = 'i_MBEW_out'.
    s_fieldcatalog-seltext_l = 'Material'.
    append s_fieldcatalog to t_fieldcatalog.
    clear s_fieldcatalog.
    s_fieldcatalog-col_pos = 3.
    s_fieldcatalog-fieldname = 'MAKTX'.
    s_fieldcatalog-tabname = 'i_MBEW_out'.
    s_fieldcatalog-seltext_l = 'Material Description'.
    append s_fieldcatalog to t_fieldcatalog.
    clear s_fieldcatalog.
                     I am getting EPC Error like " Char. strings w/o text elements will not be translated:
    'Plant'"
         Can u please tell me How to correct these type of EPC Error's.
    Thanks,
    Gopi.

  • "Get Variants" button disabled after error message in AT SELECTION SCREEN

    Hi,
    In "AT SELECTION SCREEN" I throw an error message if certain criteria return no data. 
    After the error message is thrown, the button for choosing variants no longer appears to work.  I click it and the variant selection box doesn't come up.  It just changes the values that have been populated from red to black. 
    What is the code that remedies this?  If an error is thrown, it should allow you to select a variant still. 
    Thanks,
    Kevin

    "AT SELECTION SCREEN" is not an option here.  Let me clarify.
    In START-OF-SELECTION, I call another program with a SUBMIT statement.  That program uses a logical database.  So it makes no sense to move this to "AT SELECTION SCREEN".  Even when I did that, I still couldn't solve this problem. 
    If the SUBMIT statement returns no data (if sy-subrc = '4') then I need to go back to the initial screen.  I need to display some kind of message, of type I or E or S, I don't care. 
    It just needs to go back to the selection screen and VARIANTS need to WORK, and you need to be able to SAVE the variants.
    For some reason, if I get no data with the SUBMIT statement, I can display a message and get back to the selection screen but variants do not work.  I've tried EXIT, STOP, CALL SELECTION SCREEN 1000 (the only one in the program), END LIST-PROCESSING, etc.  NOTHING WORKS!

  • Dynamic variant calling multiple selection screens

    Hi all,
    The concerned issue is that i am trying to execute a report( which on execution throws a selection screen) from a program using 'submit' statement passing a variant. along with it iam creating a dynamic varinat using FM RS_CREATE_VARIANT, the variant is being made, but on execution , the program throws an error meassage " invalid variant called'.
    This is because the varinat is calling multiple  screens , although only one screen number is passed in teh FM,( screen no 0170).
    Please tell me the possible solution fr this .
    Cheers,
    Thanks in advance.

    Hi,
    first try to pass only the static variant with the submit statement and c whether its working properly.
    and than check for dynamic variant..
    c the difference and let me know what happens ??
    thanks
    ravi aswani

  • Can I call a selection-screen that is in another function group?

    I am writing a function module in function group ZFG_A.
    There exists a Dypro 9001 that exists in function group ZFG_B.
    How can I call the dynpro 9001 from my function in ZFG_A?
    This is not OO so I am not sure how to qualify the 9001?  Such as ZFG_B=>9001
      call selection-screen 9001 starting at 5 5
                                 ending   at 70 15.
    I get compile errors on the selection-screen variables because they are not found.
    Thank you,
    Olivier

    Its not at all possible to call a screen of different program from other program.
    But u can copy the screen using a FM called 'RS_SCRP_COPY' or 'RS_SCREEN_COPY'. In the former u can copy the screen with out popup but u have to specify the SOURCE program name and screen number and TARGET program name and screen no.
    In the later u ll get the popup similar to when u copy a screen in SE51.In the popup as u know u have to enter source name and screen no. and target program name and screen no.
    Thanks & Regards
    Santhosh

Maybe you are looking for

  • Just update to 10.6.3 and NWN2 no longer works.

    Alright I updated to the latest operating system and suddenly when ever I try and load a game, start a new game in Neverwinter Nights 2 the game crashes to the desktop. I checked and the update didn't screw with any permissions I can find and I even

  • MY ITUNES WONT OPEN?, can anyone help???

    when i double click on my itunes icon to open it wont open, i have reinstalled it about four times and still nothing, anyone got any idea"s?

  • Full text search in BLOB columns NOT Working

    Hi, I am using Oracle 9i. Presently I use following code to create index. begin Ctx_Ddl.Drop_Preference ('text_only'); end; begin Ctx_Ddl.Create_Preference ( 'text_only', 'basic_lexer'); Ctx_Ddl.Set_Attribute ( 'text_only', 'index_text', 'true' ); Ct

  • Calculate BED & relevant duties based on value @ PO for a particular vendor

    Dear experts, Is it possible to calculate excise duties and other relevant pricing elements at purchase order level based on VALUE and capture the same (part1 - MIGO and part11-J1IEX) for a PARTICULAR VENDOR INVOICE? The business process is like this

  • Installing solaris in virtual box

    HI Everyone i have installed solaris 10/09 os in oracle virtual box 4.0.2 Im facing following problems as mentioned below 1. I have installed usb driver and network driver for the virtual box and i have succesfully installed the extension packs also