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

Similar Messages

  • Add a button in report selection screen

    Hi Experts,
         I want to add a userdefined button in report selection screen....so far i have written code like this,...
    TABLES : sscrfields.
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-010.
    PARAMETERS: P_ID LIKE ZBAPITABLE-ID,
                P_NM LIKE ZBAPITABLE-NAME.
    SELECTION-SCREEN END OF BLOCK B1.
    SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-020.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (11) TEXT-001 FOR FIELD R1.
    PARAMETERS: R1 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (10) TEXT-002 FOR FIELD R1.
    PARAMETERS: R2 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (10) TEXT-003 FOR FIELD R1.
    PARAMETERS: R3 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (10) TEXT-004 FOR FIELD R1.
    PARAMETERS: R4 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN END OF BLOCK B2.
    SELECTION-SCREEN: FUNCTION KEY 1.
    MOVE 'SAVE' TO sscrfields-functxt_01.
    If i use code like this button was added in application tool bar
    but in my selection screen i have  two blocks ....in first block i have input fields, and in second there is set of radio buttons...Just below that i want to put one button ....how it is possible...
    can anyone plz help me?
    Regards,
    veena.

    Here's th docu link:
    [Pushbuttons on the Selection Screen|http://help.sap.com/saphelp_nw70/helpdata/en/9f/dba81635c111d1829f0000e829fbfe/frameset.htm]
    Regards,
    Clemens

  • 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

  • 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

  • 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.

  • 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.

  • Hiding Screen fields in a Report selection screen

    Hi Experts,
    I have a requirement to hide/disable  screen fields in a report selection screen when the user clicks on some radio buttons .
    Here is the scenario,
    1) There are 4 radio buttons four radiobuttons in one group on the selection screen:--  
    Block no:1
    PARAMETER: r_not  TYPE c RADIOBUTTON GROUP a1 DEFAULT 'X'.
    PARAMETER: r_prgs TYPE c RADIOBUTTON GROUP a1.
    PARAMETER: r_remv TYPE c RADIOBUTTON GROUP a1.
    PARAMETER: r_noresp TYPE c RADIOBUTTON GROUP a1.
    2) Based on the user clicking/selecting the radio buttons no.2,3 nad 4 i need to hide some fields in the other selection block
    in the selection screen.The parameters are as follows:
    Block no:2( These fields need to be hidden/disabled)
    PARAMETER: r_occ(3) TYPE c OBLIGATORY DEFAULT '1'.
    PARAMETER: r_and TYPE c RADIOBUTTON GROUP g1.
    PARAMETER: r_or  TYPE c RADIOBUTTON GROUP g1.
    PARAMETER: r_days(3) TYPE c OBLIGATORY DEFAULT '1'.
    Thanks

    Contd.....
    AT SELECTION-SCREEN.
      CASE SSCRFIELDS-UCOMM.   
          "When Customer button is clicked set flag 1
        WHEN 'FC01'.
          L_FLAG = '1'.
          "When Sales Order button is clicked set flag 2
        WHEN 'FC02'. "Sales order
          L_FLAG = '2'.
          "When Execute button is clicked set flag 4
        WHEN OTHERS.
          L_FLAG = '4'.
      ENDCASE.
    AT SELECTION-SCREEN OUTPUT.
    CASE L_FLAG.
        WHEN '1'.  "When Customer button is clicked
          LOOP AT SCREEN.
            "Set the Production and Customer Block as inactive
            IF  SCREEN-GROUP1 = 'BL1' OR SCREEN-GROUP1 = 'BL3'.
              SCREEN-ACTIVE = '0'.
              MODIFY SCREEN.
            ENDIF.
          ENDLOOP.
        WHEN '2'. "When Sales Order button is clicked
          LOOP AT SCREEN.
            "Set the Production and Customer Block as inactive
            IF  SCREEN-GROUP1 = 'BL1' OR SCREEN-GROUP1 = 'BL2'.
              SCREEN-ACTIVE = '0'.
              MODIFY SCREEN.
            ENDIF.
          ENDLOOP.
        WHEN '3'.   "When Refresh button is clicked
          LOOP AT SCREEN.
            "Set the all Blocks as active
           IF  SCREEN-GROUP1 = 'BL2' OR SCREEN-GROUP1 = 'BL3' OR SCREEN-GROUP1 = 'BL1'.
              SCREEN-ACTIVE = '1'.
              MODIFY SCREEN.
            ENDIF.
          ENDLOOP.
        WHEN OTHERS."When Execute button is clicked
          "Set the Sales order and Customer Block as inactive
          LOOP AT SCREEN.
            IF  SCREEN-GROUP1 = 'BL2' OR SCREEN-GROUP1 = 'BL3'.
              SCREEN-ACTIVE = '0'.
              MODIFY SCREEN.
            ENDIF.
          ENDLOOP.
      ENDCASE.
    ENDFORM.      

  • How can we read the screen field values from the report selection screen wi

    Hi expart,
    How can we read the screen field values from the report selection screen with out having an ENTER button pressed  .
    Regards
    Razz

    use this code...
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_posnr.
    **Read the Values of the SCREEN FIELDs
    CALL FUNCTION 'DYNP_VALUES_READ'

  • Object text not coming in report selection screen

    Hi,
    i have an object task type for which text has been loaded.this is included in one reports selection screen.But in F4 only kee is displayed and not text.If check button is pressed text is displayed besides key.Also text doesnt come after report is executed.
    please help.
    Thanks,
    Prasanna N.

    Hi Prasanna,
    In the Query Designer goto the properties of the required object that you want to display key and text for it, Select the Key and Text Display option. Then you can see in report key and text for that object.
    Hope this helps.
    Veerendra.

  • Button on standard selection screen

    HI experts , can any budy tell me , that, can we put a button on the standard selection screen , means on screen no 1000, PLease suggest ur ans, i have a requirement to create a button on the first selection screen by selection the check box on the standard selection screen , a button should be appear on the standard selection screen.
    THanks in advance,
    Rahul

    Hello,
    What do you mean by "but ur second concept is wrong we can set our own pf-status then how can u say that set the status".
    Read again what I wrote! I said that the solution for your problem is to create a PF status of your own and that one will substitute the STANDARD one. This is the reason for having to insert the Execute (F8) button on it. Otherwise, if you don't insert it, you wont be able to execute your report.
    Also, plz reply if u know the exect ans?  this is not nice to say, specialy when the answer is correct. I've inserted buttons in standard selections screen lot's of times.
    Regards.
    Valter Oliveira.

  • Problem in Report selection screen

    Hi friends,
    I have a requirement to change the selection screen dynamically .
    My actual requirement is, i have there radio buttons in the selection screen ,
    based on the click of the radio button the input blocks should get changed.
    I am able to achieve that by looping the screen in the event of selection screen output.
    My problem is if i execute the report defaultly the first radio button is selected ,
    so my first selection screen block should display but this is not displaying.
    If i write code in initilization event , this works , but this event is triggering every time
    so i am unable to use this event and i am unable to set flags also to solve this  .
    Kindly Provide me a solution.
    Thanks & Regards,
    Arun.

    Hi Arun,
    I think may be you have misssed the part user command which is to be used as follows:
    PARAMETERS RAD1 RADIOBUTTON GROUP RAD
                                          DEFAULT 'X' USER-COMMAND flag.
    If its already there, kindly copy and paste your code here so that we can help you...

  • Prob with Push Buttons in the selection screen

    Hi All,
    1) I have 6 push buttons in the selection screen(Normal Report), 3 in a first row(P11, P12, P13) and 3 in the second row(P21, P22, P23). If I press one push button(for ex P11) the other two Push buttons(P12 P13) should grey out(Inactive mode). If I press P22, P21 & P23 shoul grey out.
    2) I need color change for the Inactive push buttons.
    Thanks
    Kris

    Can you please post your selection screen definition? I don't understand what you want to achieve by greying out the other pushbuttons when one is pressed.
    Does that mean pushing one button will do nothing except greying out the buttons?
    Typically when you push a button, you want to continue to execute the required processing for that button not just grey out other pushbuttons and stay in the selection screen.
    Anyway, you can achieve that using the following logic. I am not sure how and if you can achieve the color change.
    TABLES: sscrfields.
    DATA: v_button_pushed(5).
    SELECTION-SCREEN PUSHBUTTON /1(10) p11 USER-COMMAND push1.
    SELECTION-SCREEN PUSHBUTTON 12(10) p12 USER-COMMAND push2.
    SELECTION-SCREEN PUSHBUTTON 23(10) p13 USER-COMMAND push3.
    SELECTION-SCREEN PUSHBUTTON /1(10) p21 USER-COMMAND push4.
    SELECTION-SCREEN PUSHBUTTON 12(10) p22 USER-COMMAND push5.
    SELECTION-SCREEN PUSHBUTTON 23(10) p23 USER-COMMAND push6.
    INITIALIZATION.
      p11 = 'Push11'.
      p12 = 'Push12'.
      p13 = 'Push13'.
      p21 = 'Push21'.
      p22 = 'Push22'.
      p23 = 'Push23'.
    AT SELECTION-SCREEN OUTPUT.
      CASE v_button_pushed.
        WHEN 'PUSH1'.
          LOOP AT SCREEN.
            CHECK screen-name <> 'P11'.
            screen-input = 0.
            MODIFY SCREEN.
          ENDLOOP.
        WHEN 'PUSH2'.
        WHEN 'PUSH3'.
        WHEN 'PUSH4'.
        WHEN 'PUSH5'.
        WHEN 'PUSH6'.
        WHEN OTHERS.
      ENDCASE.
    AT SELECTION-SCREEN.
      v_button_pushed = sscrfields-ucomm.

  • Problem With Push buttons on the selection screen

    Hi All,
    I've taken 3 push buttons on the selection-screen with the following syntax
    SELECTION-SCREEN: FUNCTION KEY 1,
                      FUNCTION KEY 2,
                      FUNCTION KEY 3.
    and have removed the F8 execute button using FM RS_SET_SELSCREEN_STATUS
    Now, the problem is i'm able to perform validations using At selection screen but the code after the Start-of-selection is not being triggered.
    I mean the processing is being terminated after the at selection-screen.could anyone please tell me how do i trigger some code after the event start-of-selection when a user presses a push button with sy-ucomm = FC01.

    Check the below sample program :
    REPORT ZLPRWINSPC_TMP .
    tables : mara,
             sscrfields.
    select-options s_matnr for mara-matnr.
    initialization.
    sscrfields-functxt_01 = 'Clear Selection'.
    selection-screen function key 1.
    AT SELECTION-SCREEN.
    case sscrfields-ucomm.
    when 'Clear Selection' or 'FC01'.
    clear s_matnr.
    refresh s_matnr.
    endcase.
    Thanks
    Seshu

  • Table Control on a report selection screen -not a dialog transaction screen

    Hi
    Does anyone know of a way to have table control functionality on a report selection-screen? The program needs to be able to run as a background job (ie cannot be a dialog transaction) and we need to be able to save variants with the selection-screen values.
    Any help would be appreciated.
    The key point is we want to allow the user to enter a dynamic number of rows of table data on the selection-screen, save a variant containing that data and execute the program with the variant as a background job.
    Thanks
    Nicole Knight

    Hi Nicole,
    The main problem is how to persist the data.  If you are not able to create a couple of tables then you could always utilise TVARV instead.  On a similar line to my original post you could have the button call a dialog transaction.  In here you could do your normal GUI table control.  When saving the data simply transpose each column into a separate select-option held on TVARV keyed by the 'variant name' + fieldname.  Then retrieve and transpose this back when executing the report.
    Other methods could be storing the data in cluster xy (see EXPORT TO DATABASE command).
    This seems a bit overkill for what would be a couple of maintenance dialogs.
    Cheers,
    Pete
    PS. The view cluster is just a way of hierarchically performing table maintenance across multiple related tables.  It offers a good UI for this purpose (header and item config tables) and is utilised extensively in the IMG.

Maybe you are looking for

  • HELP ReferenceError: Error #1065: Variable is not defined.

    okay i keep writing code for a button that when clicked should jump to another frame on my timeline but each time i preview it i get this error : ReferenceError: Error #1065: Variable is not defined. I NEED HELP PLEASE HOW DO I DEFINE THE VARIABLE?

  • Problem setting up 5Ghz security on WRT610Nv2 2.00.00.B05

    Was able to set up my WRT610v2 to use WEP on the 2.4 Ghz side with the same key as my old router and my network is running fine.  When I go to set up the 5Ghz side however I'm seeing a really odd problem even the Cisco tech rep I chatted with could n

  • Can I save a transparent psd file as a JPEG keeping trancparency?

    I have an Image of a chair which it was extracted from its back ground in CS3 and I want to be able to save it as a Jpeg preserving transparency.Like an object. Thanks for your attention.

  • Document type and No. range for non leading ledger

    Hi Friends, can anybody tell me about the document type and No. range I can take for the non leading ledger. Regards

  • Currentdate-1 on Date prompt

    Hi All we are using OBIEE 11g. There is a date prompt in dashboard. I need to put a default date to the propmt while runing the report. So i have selected SQL Result as default selection and Sql Query as below SELECT CASE WHEN 1=0 THEN AnyExistedDate