Calling Sub screen

Hi all,
      Iam getting a problem in calling a sub screen.
Iam getting error as below:
<b>"." or "ID .....FIELD..." expected after "SUBSCREEN".</b>
Please go through this code and suggest me
*& Module pool       Y_MP_SUB_03
PROGRAM  Y_MP_SUB_03.
tables : kna1.
data : begin of itab occurs 0,
        name1 like kna1-name1,
        land1 like kna1-land1,
       end of itab.
CALL SCREEN 100.
*&      Module  USER_COMMAND_0100  INPUT
      text
module STATUS_0100 output.
SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR 'TT'.
CALL SUBSCREEN SUB 'Y_MP_SUB_03' '110' .
endmodule.                 " STATUS_0100  OUTPUT
module USER_COMMAND_0100 input.
  case sy-ucomm.
       when 'DISP'.
          SELECT NAME1 LAND1 FROM KNA1 INTO ITAB WHERE
           KUNNR = KNA1-KUNNR.
           APPEND ITAB.
          ENDSELECT.
      WHEN 'EXIT'.
         LEAVE PROGRAM.
  ENDCASE.
endmodule.                 " USER_COMMAND_0100  INPUT
*&      Module  STATUS_0100  OUTPUT
      text

HI,
u shouldn't use that in module.u have to call that in flow logic.
PROGRAM ZBHTSTRIP.
DATA:OKCODE LIKE SY-UCOMM.
DATA: N1 TYPE I, N2 TYPE I, R1 TYPE I, R2 TYPE I.
DATA SCRNO(4) TYPE N VALUE 2001.
CONTROLS TABS TYPE TABSTRIP.
MODULE USER_COMMAND_1001 INPUT.
   CASE OKCODE.
     WHEN 'ADD'.
       R1 = N1 + N2.
       SCRNO = 2001.
       TABS-ACTIVETAB = OKCODE.
     WHEN 'MUL'.
       R2 = N1 * N2.
       SCRNO = 2002.
       TABS-ACTIVETAB = OKCODE.
     WHEN 'BACK'.
       SET SCREEN 0.
     WHEN 'CLEA'.
       CLEAR: N1,N2.
   ENDCASE.
ENDMODULE.                 " USER_COMMAND_1001  INPUT
FORM ON_CTMENU_FORM1 USING MENU1 TYPE REF TO CL_CTMENU.
  CALL METHOD MENU1->LOAD_GUI_STATUS
    EXPORTING
      PROGRAM = 'ZBHTSTRIP'
      STATUS = 'MENU1'
      MENU = MENU1.
  CALL METHOD MENU1->ADD_FUNCTION
    EXPORTING
       FCODE = 'EXIT'
       TEXT = 'EXIT'.
ENDFORM.
MODULE STATUS_1001 OUTPUT.
SET PF-STATUS 'xxxxxxxx'.
  SET TITLEBAR 'TIT1001'.
ENDMODULE.                 " STATUS_1001  OUTPUT
FLOW LOGIC:
PROCESS BEFORE OUTPUT.
MODULE STATUS_1001.
<b>CALL SUBSCREEN SUBA INCLUDING 'ZBHTSTRIP' SCRNO.</b>
PROCESS AFTER INPUT.
MODULE USER_COMMAND_1001.
CALL SUBSCREEN SUBA.
PROCESS BEFORE OUTPUT.
MODULE STATUS_2001.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_2001.
PROCESS BEFORE OUTPUT.
MODULE STATUS_2002.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_2002.
rgds,
bharat.

Similar Messages

  • Regarding call sub screen dynamically

    hi to all,
    Is it possible to call subscreen dynamically means we are calling subscreen like
    PROCESS BEFORE OUTPUT.
    CALL SUBSCREEN SUB INCLUDING 'YSU_SUBSCREEN' '0120'.
    MODULE STATUS_0100.
    suppose we r coding like calls subscreen at the initially whenever display main screen but my requirement is
    i have edesigned 3 or 4 sub screens for vendor,material ..etc for up dation
    i  place the button regarding vendor whenver i press the button vendor that subscreen will display in that i designed insert delete update operations of vendor data like that all the screens
    for this operation can't use tabstrip control
    please provide solution
    thanks and regards,
    surya.

    Hello Surya,
    Based on a particular function code or click of a button it is possible to bring different subscreens into the normal screen's area reserved for calling subscreen
    ........so in the subscreen we need to give fields and structures required to be displayed on clicking a particular button or recieving a condition
    Please check the following
    declare a variable : loc_dynnr type sy-dynnr,
                                loc_repid  type sy-repid .
    assign a default value:
    loc_dynnr  = 120. "First subscreen being called
    loc_repid   = sy-repid. "report id 'YSU_SUBSCREEN'   
    we will be using the statement
    "CALL SUBSCREEN SUB INCLUDING 'YSU_SUBSCREEN' '0120'.
    CALL SUBSCREEN: SUB INCLUDING loc_repid  loc_dynnr.
    so on clicking the button we will have different function codes captured
    case sy-ucomm.
    when 'Button1'.
    loc_dynnr  = 120. "required subscreen to be called
    loc_repid   = sy-repid. "report id 'YSU_SUBSCREEN'   
    when 'Button2'.
    loc_dynnr  = 130. "required subscreen to be called
    loc_repid   = sy-repid. "report id 'YSU_SUBSCREEN'  
    when 'Button3'.
    loc_dynnr  = 140. "required subscreen to be called
    loc_repid   = sy-repid. "report id 'YSU_SUBSCREEN'  
    endcase.
    and in the calling code use...
    CALL SUBSCREEN: SUB INCLUDING loc_repid  loc_dynnr.
    please remember to put default values for loc_repid ,loc_dynnr..otherwise it may dump
    Pls check and revert..rewards if helpful
    also check the following link
    Re: Module Pool Program : Calling Subscreen in a Normal Screen
    Regards
    Byju

  • How to call a sub screen from abap report

    Hellow friends,
    how to call sub screen 1001 prog name SAPLMGD1
    and main program SAPLMGMM screen 4000 of tcode MM02.
    i need to call the sub screen from abap report

    Hi Rajesh,
    You can use FM MATERIAL_MAINTAIN_DIALOGUE to go to subcreen MRP1 in MM02.
    Please check this sample code from other thread and enter 'MRP 1' for p_dytxt.
    REPORT zsritest.
    TABLES mara.
    DATA: lv_bilds LIKE t133a-bilds,
    ls_t130m LIKE t130m,
    ls_rmmg1 LIKE rmmg1,
    lwa_view TYPE mbildtab,
    lwa_auswg TYPE mgauswg,
    lt_views TYPE STANDARD TABLE OF mbildtab INITIAL SIZE 0,
    lt_auswg TYPE STANDARD TABLE OF mgauswg INITIAL SIZE 0.
    PARAMETERS: p_matnr LIKE mara-matnr,
    p_werks LIKE marc-werks,
    p_dytxt LIKE mbildtab-dytxt.
    SELECT SINGLE * FROM mara WHERE matnr EQ p_matnr.
    CHECK sy-subrc EQ 0.
    CALL FUNCTION 'T130M_SINGLE_READ'
    EXPORTING
    tcode = 'MM02'
    kzrfb = 'X'
    IMPORTING
    wt130m = ls_t130m
    EXCEPTIONS
    not_found = 1
    wrong_call = 2
    OTHERS = 3.
    CALL FUNCTION 'BILDSEQUENZ_IDENTIFY'
    EXPORTING
    branche = mara-mbrsh
    materialart = mara-mtart
    tcode_ref = ls_t130m-trref
    * KZRFB = ' '
    IMPORTING
    bildsequenz = lv_bilds
    * KZ_BILDS_CHANGED =
    EXCEPTIONS
    wrong_call = 1
    not_found = 2
    OTHERS = 3.
    CALL FUNCTION 'SELECTION_VIEWS_FIND'
    EXPORTING
    bildsequenz = lv_bilds
    pflegestatus = mara-pstat
    TABLES
    bildtab = lt_views[]
    EXCEPTIONS
    call_wrong = 1
    empty_selection = 2
    OTHERS = 3.
    ls_rmmg1-matnr = mara-matnr.
    ls_rmmg1-werks = p_werks.
    READ TABLE lt_views INTO lwa_view WITH KEY dytxt = p_dytxt.
    CHECK sy-subrc EQ 0.
    lwa_auswg-auswg = lwa_view-auswg.
    APPEND lwa_auswg TO lt_auswg.
    CALL FUNCTION 'MATERIAL_MAINTAIN_DIALOGUE'
    EXPORTING
    irmmg1 = ls_rmmg1
    * IRMMG1_REF = ' '
    KZ_EIN_DARK = 'X'
    t_tcode = 'MM02'
    * FLG_MATNR_RES = ' '
    p_pstat = mara-pstat
    * FLG_STAT_ALL = ' '
    * CALL_MODE2 = ' '
    * IMPORTING
    * MATERIAL_NO =
    * UPDATE_OK =
    TABLES
    iauswg = lt_auswg[]
    EXCEPTIONS
    no_authority = 1
    OTHERS = 2.
    IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    * WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    Regards,
    Ferry Lianto

  • Calling a sub screen in an normal screen

    Hi,
    In module pool program i am having a normal screen 9000.
    In this normal screen i have call subscreens depending on the radio buttons the user selects.
    can we do like that. that is if one radio button one sub screen should be triggered and remaining should be deactivated, and if another radio button relavent sub screen should be triggered.
    please do help me its urgent.
    replies with helpful code is much appreciated.
    regards
    Mac

    Hi,
    Try to use this...
    First, put all the objects in the subscreen in the same group number with the same group name.
    Then put a function code to the radio-button that you will use to hide the subscreen.
    And into the PBO of the subscreen,
    insert this code...
      CASE sy-ucomm.
        WHEN <function code>.
          IF <radio_button> = 'X'.
            LOOP AT SCREEN.
              IF screen-group1 = '1'.
                screen-invisible = 1.
                MODIFY SCREEN.
              ENDIF.
            ENDLOOP.
          ENDIF.
      ENDCASE.
    Hope this may help you..
    Enjoy...
    Salem_M

  • Encapsulated transaction call from a (sub) screen

    Hi all,
    i want to built a customer transaction what calls an amodal window movable over the calling session and i want to display a standard transaction in the underlying original session, e.g. FB03.
    My problem is, that when i have opened the amodal window and i call FB03 afterwards, the amodal window is closed. If i leave FB03 i run trough the PBO of my calling screen and i reopen the amodal window again.
    So: Is there any chance, to encapsulate the called transaction, so that it is displayed in my calling window without terminating the transaction what has called it? From a subscreen? From a container?
    I remember that similar standard functionality may exist in workflows, but i am not sure.
    Thanks in advance for any hints.
    Axel

    HI,
       It is not possible to call a sub screen from a sub screen.
    Rgds
    Umakanth

  • How to create a new field in a sub screen in material master. ?

    How to create a new field in a sub screen in material master. ?
    Kindly help us.
    LIke wise tell me how to create a new sub screen as per my desired

    Follow the documentation of Logistics - General->Material Master->Configuring the Material Master->Create Program for Customized Subscreens  to add the new field in material master.
    Create Program for Customized Subscreens
    In this IMG activity, you can create a function group of your own by copying function group MGD1 (for industry) or function group MGD2 (for retail). The subscreens are not copied, except for two subscreens which are copied for technical reasons. You can use this copy to create subscreens of your own which you can assign to a data screen in the activity Define Structure of Data Screens for Each Screen Sequence.
    Requirements
    Be sure to read the program documentation first.
    Activities
    1. Create a function group of your own by choosing Execute.
    2. Enter a name containing up to 25 characters, beginning with the letter Y or Z, and choose Save.
    3. Access the Object Navigator.
    You do this from the SAP standard menu by choosing Tools -> ABAP Workbench, and then Object Navigator.
    4. Display either program SAPLMGD1 (industry) or SAPLMGD2 (retail) as required.
    5. Copy the subscreens as required, ensuring that they already contain as many as possible of the field names you want to use in your function group. You do this as follows:
    a) Choose Screens, position the cursor on the corresponding subscreen, and choose Copy in the context menu.
    b) Enter the program to which you want to copy the subscreen, prefixing it with SAPL, and enter a screen number. Use the screen number of the original subscreen where possible. If the F1 help is specific to a particular subscreen, this ensures that this context-specific help continues to be displayed.
    Example
    You have called your function group YENTERPRISE, to which you want to copy subscreen SAPLMGD1 2301. Enter SAPLYENTERPRISE as the program to which the subscreen is to be copied, and enter (preferably) 2301 as the screen number.
    6. Return to the initial screen of the Object Navigator and display your program. In the example above, you would enter SAPLYENTERPRISE.
    7. Choose Update object list.
    8. Select the subscreen you have copied and activate it by choosing Activate in the context menu.
    Using the Screen Painter, you can remove fields you do not require on the subscreen or include additional fields from other subscreens (see the ABAP Dictionary). For information on the Screen Painter, see the SAP library documentation BC ABAP Workbench Tools.
    Points to consider when removing or adding fields
    Make sure that a field statement exists for each field on the subscreen since data may not otherwise be transported correctly. You can use subscreen SAPLMGD1 2002 as an example.
    For the fields you have added, include any check modules and modules for self-programmed F4 help that are called up for these fields on the original subscreen. You can do this by displaying the flow logic for the original subscreen and searching for such modules. They normally have the same names as the fields themselves. When you find a module, copy the corresponding module call to your subscreen.
    If you change the order in which fields are transported that are checked together in the flow logic (such as the safety stock and minimum safety stock), you must deactivate the check module for the first field and activate it for the second. The system would otherwise transport the first field, and carry out the check before the second field is transported.
    Any error messages that fields are unknown when activating the subscreen are due to the fields still being included in checks, even though you have removed the fields from the subscreen. Search for the fields in the source code and make the lines in which they appear comment lines. Then reactivate the screen.
    9. Assign the subscreen to a data screen as required.
    Note on transport
    Use the Workbench Organizer to transport the copy you have created.
    Proceed

  • SELECT-OPTIONS in Module Pool Sub-Screen

    Hi,
    I have been working on a Module-Pool Development, in the header portion of the Screen, I have provided a Selection-Screen as a Sub-Screen because the requirement specifies to display a SELECT-OPTION in the Header Area.
    Now the problem is that, when working with the Screen, as soon as I press <ENTER> the Main Screen re-calls the Selection-Screen in the Sub-Screen area and all the entries made in the Selection-Screen are reset/erased.
    Kindly provide a solution either to stop the <ENTER> action to re-call the sub-screen. Or on any alternate method(s) to  provide a SELECT-OPTION on a Module Pool based Screen UI.
    MAIN SCREEN Code:
    *  PROCESS BEFORE OUTPUT
    PROCESS BEFORE OUTPUT.
    *~  Set PF-STATUS and TiTLE for Screen 100
      MODULE status_0100.
    *~  Call the Subscreen Dynamically
      CALL SUBSCREEN subscr1 INCLUDING sy-cprog gv_dynnr1.
      CALL SUBSCREEN subscr2 INCLUDING sy-cprog gv_dynnr2.
    *  PROCESS AFTER INPUT
    PROCESS AFTER INPUT.
    *~  Handle the Exit Commands of Screen 100
      MODULE user_command_0100 AT EXIT-COMMAND.
    *~  Handle the User Command(s) for screen 100
      MODULE user_action_0100.
      CALL SUBSCREEN subscr1.
      CALL SUBSCREEN subscr2.
    So whenever <ENTER> is pressed, the PBO re-calls:
    CALL SUBSCREEN subscr1 INCLUDING sy-cprog gv_dynnr1.
    and the Selection-Screen is reset.
    Regards,
    Nishant Nayyar.

    Haii Nishant,
    This problem was earlier solved by one of the members and after going through it i have now created a select-option in the Subscreen. Just create two input fields, name them as if they were low and high (for convinience as in case of select-option).
    U now need to create a table of type rstabfield.
    Ex: gt_rstab_bukrs type rstabfield.
    Now create a button and assign a Fcode for it. When you click on this button then u need to implement the ranges functionality as in select-option. For that use the following function module:
    CALL FUNCTION 'COMPLEX_SELECTIONS_DIALOG'
    EXPORTING
      TITLE                   = ' '
       TEXT                    = ''
       SIGNED                  = 'X'
       SEARCH_HELP             = 'H_T001'
       TAB_AND_FIELD           = gt_rstab_bukrs
      TABLES
        RANGE                   = rg_bukrs1.
    Hope it helps.
    Best Regards,
    rama

  • ALV Grid: refresh in sub screens

    Hello All,
    I have some issues with internal table display in ALV grid.
    The following is the scenario.
    I am in a wizard which has 2 sub screens (SScreen 1 and sscreen 2).
    1)On sscreen 1, i have a input field,where i provide a value and on clicking the next button i get a list of values which i display on sub screen 2 using ALV grid.
    2)Now i go back to sscreen1 and change the value in the input field,since i use on-request module, i know the value in the field has changed and now i need to display new set of values on sscreen 2.
    In this case i clear the internal table, get new values for internal table and then call set_values_for_first_display().However i still get the old values displayed on SScreen 2!!!!.
    Any suggestions on what i might be doing wrong?
    Cheers
    Dev

    Hi Vijay,
    Thanks for the info.
    I will try refresh_table_display option after getting to work in a couple of hours.
    I am initializing the grid and control everytime i change a value on Subscreen 1 in the PBO of Subscreen 2(the screen where the ALV list is displayed).
    That is the reason why i call set_table_first_display, whenever there are new values in the internal table and avoid refresh_table_display.
    Cheers
    Dev

  • Sub screen: Handling the Radio button selection?

    Hi,
    Scenario:
    I have a Main screen and a sub screen. From the main screen I am calling the sub screen. On the Sub screen, I have 2 radio button. On the selection of the Radio buttons, I am activating/deactivating few of the screen elements on the sub screen.
    I have grouped the radio button and also tried assigning Function code to it, but in vain..:(
    Issue
    I am not able to handle the event triggered by the selection of the radio buttons?
    Kindly suggest.
    Regards
    s@k

    Hi,
    Are you still have any Issue, Let us know
    In the Main Screen Element List there is a field OK_CODE pass an entry into it
    in the TOP Include
    DATA : OK_CODE type SY-UCOMM. " This captures the OK_CODE from the Screen.
    Since SUb Screen cant have their Own OK_CODE this can be handled in the Main Screen only
    Try in PAI of Sub Screen using OK_CODE if it is not working then Implement the same in PAI of Main Screen
    The system will generate UCOMM for Radio Button since they are in One Group only. Each Radio button cannt have a separate UCOMM assigned. In Screen Painter (if It is Module Pool) assign a FCode for the Radio Button.
    Even if try changing the FCODe Value they still will have the New Changed Value but cannot be changed.
    This automatically triggers PAI . only way to capture it is check
    case ok_code. " Optionally you can omit this
    when  ok_code = 'RAD'.  " This is common for all the Radio BUttons but cant be different
    if r1 = 'X'.
    elseif r2 'X' " Etc.
    endif.
    endcase.
    Ram
    Edited by: Ramchander Krishnamraju on Feb 26, 2010 10:37 AM

  • Problem with sub-screen actions on Cancel button

    Hi all,
    I have a problem with sub-screen.
    I created a subscreen (screen sequence in MM01/MM02/MM03). When users leave this screen, I call POPUP_TO_CONFIRM to ask if they want to save the data.
    1) My goal is: when they choose Cancel, no actions are performed and users will see the current screen. However, I cannot use command: SET SCREEN 0 or LEAVE TO SCREEN 0 because the system gives an error message:
    *SET SCREEN not allowed in subscreens*.
    2) How can we determine when the user leaves the screen? which value of SY-UCOMM will be used to check this?
    Thanks in advance.

    for dis SET SCREEN is not required.
    Consider d code given below as n eg:
    CALL FUNCTION 'POPUP_TO_CONFIRM'
        EXPORTING
          titlebar              = 'SAVE'
          text_question         = 'SOME _QUS'
          text_button_1         = 'YES'
          text_button_2         = 'NO'
          default_button        = '2'
          display_cancel_button = ' '
        IMPORTING
          answer                = l_ans
        EXCEPTIONS
          text_not_found        = 1
          OTHERS                = 2.
      IF sy-subrc <> 0.
        MESSAGE e066.
      ENDIF.
    IF l_ans EQ '1'.    " when yes is pressed
       MODIFY db.
       commit work.
       leave program.
    ELSEIF l_ans EQ '2'.  "when no is pressed
        leave program.
    ELSE.     " when cancel is pressed
    ENDIF.
    In above module when Yes is pressed it saves data den leave prog.
    As no action is specified for cancel button it will remain on that screen only from which popup is called, in this way ur problem can be solved.
    Reward properly.

  • Why the multiple selection can't work in sub screen

    hi experts:
         when i try to use the sub-screen in the report,why the multiple selection function(SO_BCTXT) can't work normally in screen 1095:
    the coding as below.will reward points if solve this issue
    the main program in Subscreen:
    PROCESS BEFORE OUTPUT.
    module status_1005.
      CALL SUBSCREEN area INCLUDING sy-repid lv_tab_number.
    PROCESS AFTER INPUT.
      MODULE cancel AT EXIT-COMMAND.
      CALL SUBSCREEN area.
      MODULE user_command_1005.
    module user_command_1005 input.
      my_ok = ok_code.
      clear ok_code.
      case my_ok.
        when 'TAB1'.
          mytabstrip-activetab = my_ok .
          lv_tab_number = 1095.
        when 'TAB2'.
          mytabstrip-activetab = my_ok .
          lv_tab_number = 1096.
        when 'CRET' or 'ONLI'.
          perform get_bc_set
                 using
                    so_chanb[]
                 changing
                    <fs_bcsetfield> .
          leave to screen 0.
      endcase.
    endmodule. 
    in the screen 1095:
    PROCESS BEFORE OUTPUT.
    MODULE %_INIT_PBO_J.
    MODULE %_PBO_REPORT.
    MODULE %_PF_STATUS.
    MODULE %_SO_BCTXT.
    MODULE %_END_OF_PBO.
    PROCESS AFTER INPUT.
    MODULE %_INIT_PAI_J.
    CHAIN.
      FIELD  SO_BCTXT-LOW.
      FIELD  SO_BCTXT-HIGH.
      MODULE %_SO_BCTXT.
    ENDCHAIN.
    FIELD !INCBCTY1 MODULE %_INCBCTY1 .
    FIELD !INCBCTY2 MODULE %_INCBCTY2 .
    FIELD !INCBCTY3 MODULE %_INCBCTY3 .
    FIELD !INCBACT MODULE %_INCBACT .
    FIELD !INCBINAC MODULE %_INCBINAC .
    FIELD !INCLMAND MODULE %_INCLMAND .
    FIELD !INCLOPTI MODULE %_INCLOPTI .
    CHAIN.
      FIELD  SO_BCTXT-LOW.
      FIELD  SO_BCTXT-HIGH.
      FIELD INCBCTY1 .
      FIELD INCBCTY2 .
      FIELD INCBCTY3 .
      FIELD INCBACT .
      FIELD INCBINAC .
      FIELD INCLMAND .
      FIELD INCLOPTI .
      MODULE %_BLOCK_1095001.
    ENDCHAIN.
    CHAIN.
      FIELD  SO_BCTXT-LOW.
      FIELD  SO_BCTXT-HIGH.
      FIELD INCBCTY1 .
      FIELD INCBCTY2 .
      FIELD INCBCTY3 .
      FIELD INCBACT .
      FIELD INCBINAC .
      FIELD INCLMAND .
      FIELD INCLOPTI .
      MODULE %_END_OF_SCREEN.
      MODULE %_OK_CODE_1000.
    ENDCHAIN.
    in the main report
    selection-screen begin of screen 1095 as subscreen.
    enquire Data
    data l_text       type as4text.
    selection-screen begin of block b1 with frame title text-024.
    select-options :
      so_bctxt     for l_text .
    selection-screen skip 1 .
    parameters:
      incbcty1    type c as checkbox default abap_true ,
      incbcty2    type c as checkbox default abap_true ,
      incbcty3    type c as checkbox default abap_true .
    selection-screen skip 1 .
    parameters:
      incbact      type c as checkbox default abap_true ,
      incbinac     type c as checkbox default abap_true .
    selection-screen skip 1 .
    parameters:
      inclmand     type c as checkbox default abap_true ,
      inclopti     type c as checkbox default abap_true .
    selection-screen end of block b1.
    selection-screen end of screen 1095 .

    Hiii
        In main program you have dclared subscreen area.
    now First of all you have to declare a selection screen in your main program
    selection-screen begin of screen 1005 as subscreen.
    SELECT-OPTIONS s_bukrs1 for  v_bukrs.   "whatever you want in selection screen
    selection-screen end of screen 1005.
    IN PBO of your main screen (not in 1005) write
    call subscreen SUB1 including sy-repid '1005'.
    where SUB1 is your subscreen area name. And remember don't touch PBO or PAI of your 1005 screen, otherwise it will give you error. Yuo can just put text in layout of 1005 screen. but don't disturb other things.

  • Adding column in sub screen

    Hi every one,
    I have 10 columns in my sub screen, i would like to add one more column in that, can any one help me, how to create a new column in the sub screen.
    ex:
    Columns:          a   b   c    d  
                            1   2   3    4
                            2   3   4    5
    Now i want to add "e" column.
    Thanks in advance.

    The field should be tagged as Input on the parameter screen for that field.  You can get there by
    double clicking on the field in the first row of the table control.  To get the values updated to the
    actual internal table, there is a routine in the PAI that should look something like this.
    *&spwizard: pai flow logic for tablecontrol 'TC_202'
      LOOP AT mt_approvers.
        CHAIN.
          FIELD mt_approvers_rec-division.
          FIELD mt_approvers_rec-branch.
          FIELD mt_approvers_rec-appr_level.
          FIELD mt_approvers_rec-userid.
          FIELD mt_approvers_rec-name.
          MODULE tc_202_modify ON CHAIN-REQUEST.
        ENDCHAIN.
        FIELD mt_approvers_rec-sel
          MODULE tc_202_mark ON REQUEST.
      ENDLOOP.
      MODULE tc_202_user_command.
    *&spwizard: module TC_202_change_tc_attr.
    *&spwizard: module TC_202_change_col_attr.
    You will need to add your field to the FIELD list.
    The module it calles during that loop, will/should contain the code
      MODIFY mt_approvers
        FROM mt_approvers_rec
        INDEX tc_202-current_line.
    If after changing the parameter to allow Input, should it still not allow you to input, then in the PBO
    routine there is likely code that sets the parameters to the table control to input = 0 and that would
    need to change to allow input to the appropiate columns.

  • Sub Screen in Screen Painter

    I created a screen in the screen painter and it works fine .
    Now i want when i push a button to display a small selection criteria in a window subscreen (?) so to take some result.
    I dont know if this can happen . Is there any FM to do this ?
    Thanks a lot ...

    hi,
    for this u hav to do following steps
    >>Define the sub-screen area(s) on a screen. Resizable, Minimum size and scrollable are the attributes
    >>Define suitable sub-screen screens
    >>Include the sub-screen screen in the sub-screen area.
    >>Adjust the frame of the sub-screen within the "main" screen. Name the sub-screen in the Field name field.
    >>Arrange the fields within the sub-screen so that they appear in the main screen .
    >>You include a subscreen screen using the CALL SUBSCREEN statement in the flow logic of the main screen.
    To include a subscreen screen in the subscreen area of the main screen and call its PBO flow logic, use the following statement in the PBO event of the main screen:
    PROCESS BEFORE OUTPUT.
      CALL SUBSCREEN  in the PBO event. This can call PAI modules of the ABAP program in which the subscreen screen is defined. Data is transported between identically-named fields in the subscreen screen and the ABAP program either when the PAI event is triggered, or at the corresponding FIELD statements in the PAI flow logic of the subscreen screen.
    thanks
    Sachin

  • Dialog Programming(module pool):call a screen to subscreen area.

    Hi experts,
    I want to call a screen created in the function group into my
    subscreen area of current screen of main program.
    I have done the below way :
    1. Created a screen 100 in the module pool program z_bpmodule.
    2.created a subscreen area SUB in screen 100.
    3. I hav created function group :zfungroup
    and  a screen 300,a function module Z_EXPORT_FUN for exporting the data to the screen 300 from report.
    Now my prog is lik below :
    PROGRAM  Z_SUBSCREEN1.
    DATA : ZMATNR LIKE MARA-MATNR.
    DATA : DYNNR LIKE SY-DYNNR .
    *&      Module  STATUS_0100  OUTPUT
          text
    MODULE STATUS_0100 OUTPUT.
    SET PF-STATUS 'xxxxxxxx'.
      SET TITLEBAR 'TITLE'.
    ENDMODULE.                 " STATUS_0100  OUTPUT
    *&      Module  EXPORT_DATA  OUTPUT
          text
    MODULE EXPORT_DATA OUTPUT.
    CALL FUNCTION 'Z_EXPORT_FUN'
                              EXPORTING Z_INPUT = ZMATNR.
    ENDMODULE.                 " EXPORT_DATA  OUTPUT
    *&      Module  USER_COMMAND_0100  INPUT
          text
    MODULE USER_COMMAND_0100 INPUT.
    CASE SY-UCOMM.
    WHEN 'EXP'.
    DYNNR = '0300'.
    *ENDCASE.
    ENDMODULE.                 " USER_COMMAND_0100  INPUT
    and the flow logic is lik this :
    PROCESS BEFORE OUTPUT.
    MODULE STATUS_0100.
    MODULE EXPORT_DATA.
    CALL SUBSCREEN SUB INCLUDING SY-REPID ' 0300'.
    PROCESS AFTER INPUT.
    MODULE USER_COMMAND_0100.
    CALL SUBSCREEN SUB.
    Now the main problem is i am not able to call the screen from function group to subscreen area...
    kindly provide the solution.....
    Thanks a lot in adv ....
    Brahma.

    I am just getting the main screen and the subscreen is not at all displaying .....
    but when i perform the PAI .. I am getting the dump ..
    Short text
        Dynpro does not exist
    What happened?
        Error in the ABAP Application Program
        The current ABAP program "Z_SUBSCREEN1" had to be terminated because it has
        come across a statement that unfortunately cannot be executed.
    What can you do?
        Note down which actions and inputs caused the error.
        To process the problem further, contact you SAP system
        administrator.
        Using Transaction ST22 for ABAP Dump Analysis, you can look
        at and manage termination messages, and you can also
        keep them for a long time.
    Error analysis
        The system attempted to use dynpro 0000 in program "Z_TX1".
        This dynpro does not exist.
    How to correct the error
        Probably the only way to eliminate the error is to correct the program.
        If the error occures in a non-modified SAP program, you may be able to
        find an interim solution in an SAP Note.
        If you have access to SAP Notes, carry out a search with the following
        keywords:
        "DYNPRO_NOT_FOUND" " "
        "Z_SUBSCREEN1" or "Z_SUBSCREEN1"
        "EXPORT_DATA"
        If you cannot solve the problem yourself and want to send an error
        notification to SAP, include the following information:
        1. The description of the current problem (short dump)
           To save the description, choose "System->List->Save->Local File
        (Unconverted)".
        2. Corresponding system log
           Display the system log by calling transaction SM21.
           Restrict the time interval to 10 minutes before and five minutes
        after the short dump. Then choose "System->List->Save->Local File
        (Unconverted)".
    3. If the problem occurs in a problem of your own or a modified SAP
    program: The source code of the program
       In the editor, choose "Utilities->More
    Utilities->Upload/Download->Download".
    4. Details about the conditions under which the error occurred or which
    actions and input led to the error.
    hope i have given the full information.
    Thanks a lot.

  • The display of sub screen exceeds the sub screen area

    Hi Experts,
      I have a requirement, that i need to make changes to one of the screens in the standard transaction. I found there is a screen exit exist for this. This screen is called in the tab strip(In the standard transaction). I have done the screen changes in the sub screen. When calling the standard transaction this sub screen exceeds the sub screen area of the standard transaction tab strip. I know if the sub screen size is more than the sub screen area then scroll bars will be displayed automatically. But i am facing a strange problem that the display of sub screen exceeds the sub screen area. I need scrol bar instead of exceeding the sub screen.
      Please help me to solve this problem
    Regards,
    Bujji

    Anyone has any suggestions for my question. Any help is much appreciated. Thanks.

Maybe you are looking for