Selection screen (application toolbar)

Hi,
Here I have following scenario:
Execute Selection screen 1(1000) -> Calls selection screen2(500) -> Calls and execute smart form
Flow is like this :
in start-of-selection.
initial coding for second screen.
Call Selection-screen 500.
Then call function 'SSF_FUNCTION_MODULE_NAME'.
Now if i click back button in smart form its going to selection screen 1which is quite acceptable, but if we are clicking BACK or CANCEL or EXIT button in selection screen 2(500) instead of going to Selection screen 1(1000) its calling the smart form. If i click debug and click back button in selection screen2 (500) the pointer is coming directly to following statement in start-of selection:
Call Selection-screen 500.
and in this time after F5 if i check sy-dynnr it comes 1000 and sy-ucomm it comes blank
Can you please tell me what code should I need to write to handle BACK, CANCEL,EXIT for second selection screen 2(500) and at which point and at which event. Please suggest.
I will definetly .............

Hi,
Write LEAVE TO SCREEN 0 in the PAI of screen 500.
MODULE user_command_0500 INPUT.
  CASE g_ok_code.
    WHEN 'BACK' OR 'EXIT'.
    Goto Selection screen
      LEAVE TO SCREEN 0.
    WHEN  'CANC' .
      LEAVE PROGRAM.
    WHEN OTHERS.
    Do Nothing
  ENDCASE.
  CLEAR : g_ok_code.
ENDMODULE.

Similar Messages

  • Disable selection screen application toolbar button

    Hi All,
    Could you please let me know how to hide or disable application toolbar pushbuttons in the selection screen default screen 1000??
    Thanks & regards,
    Santhosh

    Hi,
    Try this way.
    "Create table for function codes
    DATA: it_exclude TYPE TABLE OF sy-ucomm.
    PARAMETERS: r1 RADIOBUTTON GROUP gr1 USER-COMMAND uco1,
                r2 RADIOBUTTON GROUP gr1.
    INITIALIZATION.
      "Create two buttons with function codes FCODE1 and FCODE2.
      SET PF-STATUS 'MY_GUI'.
    AT SELECTION-SCREEN OUTPUT.
      IF r1 = 'X'.
        APPEND 'FCODE1' TO it_exclude.
        CALL FUNCTION 'RS_SET_SELSCREEN_STATUS'
          EXPORTING
            p_status  = 'MY_GUI'
          TABLES
            p_exclude = it_exclude.
      ELSE.
        REFRESH it_exclude.
      ENDIF.
    Thanks
    Venkat.O

  • Button on report selection screen application toolbar

    Hi,
    I want to place Button (application tool bar)on report(executable program) selection screen.
    Need your valuable suggestions.
    Thanks,
    Sreedevi

    hii
    1. create GUI status with "Status" name and "Short text"
    2. Now a screen will appear with the following,
                    a. Menu Bar
                    b. Application tool bar
                    c. Function keys
    3. Click the down arrow near the application toolbar
    4. Enter the function code like SAVE, EXIT, etc., You
    can also give ur own meaningful naming convention .
              For example ( ZTEST)
    5. Now press enter, it will ask for "Static text" or "Dynamic Text". Choose Static text and press enter
    6. Now it will ask for function text and Icon name. Specify some function text ( what it does ) and Icon name u want to attach.
    7. Press enter. It will ask for function keys. Specify a function key and press enter.
    8. Now u can handle this function code (ZTEST) either in PBO/PAI like IF FUNCTION = ZTEST ...ENDIF
    Note:
    Don't forget to set the GUI status u have created in PBO event.
    Example code to set PF status.
    PROCESS BEFORE OUTPUT.
    MODULE liste_initialisieren.
    MODULE setstatus_0100.
    LOOP AT extract WITH CONTROL
    tctrl_ztufi_league CURSOR nextline.
    MODULE liste_show_liste.
    ENDLOOP.
    In the above MODULE setstatus_0100 do the following,
    SET PF-STATUS 'ZGUI'. ( The GUI status u have created).
    Check this:
    <b>http://www.sapdevelopment.co.uk/reporting/selscr/but_appbut.htm</b>
    <b>http://www.sap-basis-abap.com/abap/add-button-to-alv-toolbar-with-reuse-alv-list-display.htm
    Re: How to add push buttons in out put screen of ALV
    http://www.planetsap.com/Tips_and_Tricks.htm</b>
    Regards
    Naresh

  • Creating push button on Selection screen application toolbar

    Hi Friends,
    this is a HR-ABAP report. I have to create a push button on Selection screen. when user clicks on that push button 'MODAL DIALOG BOX' has to be displayed containing some data.
    plz kindly give some sample code to do this.
    Regards,
    Radhika Dasharatha.

    Hi,
    1)Use SELECTION-SCREEN  PUSHBUTTON /10(20) PUSH USER-
      COMMAND 'ABC'. in selection screen.
    2) Give the static name to button in INITIALIZATION event like PUSH = 'PRESS'.
    3) At selection screen.
      if sy-ucomm eq 'ABC'.
    call FM HR_BE_GE_MODAL_DIALOG
    endif.
    Thanks
    Sandeep
    Reward if useful

  • How many push buttons can u place on selection screen application tool bard

    hi
    how many push buttons can u place on selection screen application tool bar
    and what is default function code for that buttons.

    Hi Chaitanya,
    You can place maximum 5 push buttons on Application Toolbar.
    please award the points incase if you are able to get the solution.
    Thanks
    Sivaram

  • Command Button on selection screen application tool bar

    Hi All,
    I want to add command Button on selection screen application bar.
    it is my z progarm .
    please suggest one sample code .
    regards,
    Ajay reddy

    Goto SE41, create a Status and the call it in your app.
    SET PF-STATUS 'TEST'.
    Greetings,
    Blag.

  • Screen Application toolbar.

    Hi Experts,
       I have created two buttons on application toolbar i.e. SAVE And CHECK.
    my requirement is when any one click on CHECK button then only SAVE button should active.
    how to do this?
    Thanks,
    Abhishek

    Hi Tarun,
    I didn't understand whether it would work with the code you have given,
    START-OF-SELECTION.
      SET PF-STATUS '<pf_status_name>' EXCLUDING 'SAVE'. "disable save button
    AT USER-COMMAND.
      CASE sy-ucomm.
        WHEN 'CHECK'.
          SET PF-STATUS '<pf_status_name>'. "enable save button when CHECK is clicked
          "other code
      ENDCASE.
    once you have set the pf-status, i doubt if it would work without using the immediately option...
    please check it out...
    Hi Abhishek,
    is it working without immediately option as well.... please do let me know as I tried from my end tarun's code was not working without immediately option and it worked with the code I pasted just before tarun.
    Regards,
    Pinaki

  • Adding pushbutton in application toolbar of HR programs  using LDB

    Hi all!
    I have a requirement to add a pushbutton in the selection screen application tool bar for the HR programs when using LDB PNP.
    Normally when we are using LDB in our program we will get a extra button provided by SAP after the execyte button. When we are creating a new button for this by using the table fields sscrfields with the function key as 2.
    But, the statement "SELECTION SCREEN FUNCTION KEY 1" is not showing any pushbutton in the application toolbar.
    The same question is already posted in SDN but no reply.
    Please provide your suggestion.
    Thanks,
    Rajan U

    Hi all!
    I have a requirement to add a pushbutton in the selection screen application tool bar for the HR programs when using LDB PNP.
    Normally when we are using LDB in our program we will get a extra button provided by SAP after the execyte button. When we are creating a new button for this by using the table fields sscrfields with the function key as 2.
    But, the statement "SELECTION SCREEN FUNCTION KEY 1" is not showing any pushbutton in the application toolbar.
    The same question is already posted in SDN but no reply.
    Please provide your suggestion.
    Ive found this keyword: SELECTION-SCREEN FUNCTION KEY n [ldb_additions].  Will this be useful??
    Thanks,
    Rajan U

  • Application toolbar list report

    Hi,
    How would I get a button on the application toolbar for an abap list report.
    I could do it using a selection screen, but I want the button usuable when the list output is printed
    to the screen. I have clickable icons on the list report. Be nice to have toolbar buttons.
    thanks
    Dylan.

    Hi you are asking about selection-screen application tool bar buttons or output application tool bar buttons. If u want selection-screen application tool bar buttons then go with SCCRFIELDS structure. If u want output application tool bar buttons then go with Set pf-status.
    Regards,
    Kumar.

  • How to create application toolbar in modal dialog box in selection-screen

    Hi Experts,
    how to create application toolbar in modal dialog box in selection-screen?
    Regards,
    Swapnika

    Hi,
    Check the following link regarding Model dialog box and appication toolbar
    http://help.sap.com/saphelp_nw70/helpdata/en/d1/801b84454211d189710000e8322d00/frameset.htm
    It helps in solving your problem.
    Thanks.
    Ramya.

  • Pushbuttons on application toolbar in selection screen

    Hi,
    I have created 2 pushbuttons in the application tool bar of selection screen using pf-status.But the other icons in the standard toolbar were grayed out because of this.can anyone tell me why this is happening.

    Hi
    you need to define those other elements of the menubar in the PF-STATUS for example for back write -
    > BACK
    for cancel----->CANCEL for save
    use these predefined function codes
    PRI
    List
    CTRL-P
    Print displayed list
    %EX
    List
    Shift-F3
    Exit processing
    PICK
    Edit
    F2
    Event AT LINE-SELECTION
    RW
    Edit
    F12 , ESC
    Cancel processing
    %SC
    Edit
    CTRL-F
    Find
    %SC+
    Edit
    CTRL-G
    Find next
    BACK
    Goto
    F3
    Back one level
    P--
    CTRL-PgUp
    Scroll to first window page
    P-
    PgUp
    Scroll to previous window page
    P+
    PgDn
    Scroll to next window page
    P++
    Ctrl-PgDn
    Scroll to last window page
    Regards
    Pavan
    Edited by: Pavan Bhamidipati on Jul 11, 2008 6:40 AM

  • Application toolbar of selection screen

    Hi,
    I'd like to add SEPARATOR (not button) to application toolbar of selection screen. Is it possible?
    Thanks
    Radoslaw

    Hi Kltys,
       Check the following sample programs:
    Selection Screen :
    demo_sel_screen_with_subscreen.
    demo_sel_screen_as_subscreen.
    demo_sel_screen_in_tabstrip.
    demo_sel_screen_with_tabstrip.
    DEMO_SEL_SCREEN_PUSHBUTTON
    D_ANALYSEREPORT_EABP_BUTTONS
    Reward Points if this helps.
    Manish
    Message was edited by: Manish Kumar

  • How to Grey(Deactivate) Function Code at application Toolbar of a screen

    Hi all,
    I want to gray(deactivate) function codes at application toolbar of a normal screen. I am using excluding addition of set pf-status but it hides the button from the application tool bar.
    I don't want to hide button, but gray only.
    Thanx in advance.

    When editing the PF-Status itself, try selecting the menu option and then F7 (the Function Code / Activate / Deactivate button, or menu Extras > Function Active <-> Inactive).
    Jonathan

  • Adding Button on application toolbar on ABAP List display screen....

    Hello Gurus,
    I copied SAP program 'RFBUEB00' into custom program. When I execute the custom report, I see the data lijne by line in ABAP list. I see a deafult 'Select' button on application toolbar.
    If I want to add additional custom button on application toolbar on ABAP list display screen, how can I do it ? Please help.
    Regards,
    Jainam.
    Edited by: Jainam Shah on Oct 27, 2009 5:44 PM

    >
    Jainam Shah wrote:
    > In my case it just rights the data in ABAP screen as follows. I can't use ALV grid and stuff because its on older version.
    >
    >
    FORM LISTE_SCHREIBEN.
    >
    >   check = '@T9@'.
    >
    >   FORMAT COLOR COL_KEY INTENSIFIED OFF.
    >   WRITE: / SY-VLINE,
    >            check,
    >            BKPF-BUKRS,
    >            BKPF-BELNR,
    >            BKPF-GJAHR.
    >   FORMAT COLOR COL_NORMAL INTENSIFIED OFF.
    >   WRITE:   BKPF-BLART,
    >        (8) BKPF-BLDAT DD/MM/YY,
    >        (8) BKPF-BUDAT DD/MM/YY,
    >            BKPF-WAERS,
    >            BKPF-XBLNR,
    >         80 SY-VLINE.
    >   XAUSGABE = 'X'.
    >   HIDE: BKPF-BUKRS, BKPF-BELNR, BKPF-GJAHR, BKPF-BSTAT, XAUSGABE.
    >   IF BKPF-BKTXT NE SPACE.
    >     FORMAT COLOR COL_KEY INTENSIFIED OFF.
    >     WRITE: / SY-VLINE, CHAR4 UNDER BKPF-GJAHR.
    >     FORMAT COLOR COL_NORMAL INTENSIFIED.
    >     WRITE:   BKPF-BKTXT UNDER BKPF-BLART,
    >              80 SY-VLINE.
    >     HIDE: BKPF-BUKRS, BKPF-BELNR, BKPF-GJAHR, BKPF-BSTAT, XAUSGABE.
    >   ENDIF.
    > ENDFORM.
    >
    >
    > I have to select multiple lines and proces them. For one line I know I can use AT-LINE-SELECTION but this is multiple lines...
    What is your SAP system version?
    It seems to be displayed only in ALV. Well, if you can make it to display in LIST ... you can go with set pf-status.
    good luck

  • How many pushbuttons u can create in application toolbar in selection scree

    Hi
    How many pushbuttons u can create in application toolbar in selection screen? 
    Thank You

    Hi,
    Use SET PF-STATUS 'ZABC'.
    Double click on it.
    It will display Application toolbar. Create the buttons.
    I think the limitation is bcz of the LABEL of button, if you create buttons with a Single TEXT, then you would be able to create many buttons, including toggle button. The Toggle button would switch the buttons.
    i.e say initially 10 buttons are displayed along with toggle button. You click the toggle button , then remaining 10 buttons are displayed.
    Best regards,
    Prashant

Maybe you are looking for

  • Lion Bootcamp won't install Windows 7 Professional

    I have a fresh install of Lion on my iMac and have been trying to install Windows 7 Professional using Bootcamp 4.0.  Here's what I've done. 1) Loaded bootcamp and followed the instructions to partition the drive.  Split the 500GB drive so the Mac wo

  • Creating partitions based on date

    Hello Friends, I want to create a table ( x_acc_nnm) with a column x_as_of_dt ( Datatype Date dd/mon/yyyy ) partition on x_as_of_dt. Want to partition the table on x_as_of_dt based on YYYYMM appreciate your help. thanks/Kumar

  • Is my iPhone hacked?

    Hi guys. Im sorry this is so long but please read! this is getting quite frustrating but my phone is out of space capacity. HOWEVER, it has been like this for the last 2 months and it still has worked fine, and i am able to save pictures by taking th

  • How are you Using iBooks Author and Samples

    I'm curious to see how everyone is using iBooks author to create books. Are most people copy/pasting content into their book or are they directly writing the content in the book? How many have just imported the information from another word processin

  • Not able to do Pegging for both MPS & MRP Workbench

    Hi Experts, We have implemented SCP (Oracle EBS 11.5.10.2). Loaded the forecast, then ran the MDS. Also ran the MPS (for finished goods). Later opened the MPS workbench, cannot see items for pegging. Please do the needful. Thanks.