Skip to Content

Way to make a list (report) with buttons in body of list ?

Hi

I need to make a list (a Log) with icons (buttons) in the body of the list (Not in the GUI status). The requirement is when user press double-click in each icon the program perform some routine. (Example the List is a Log wich says the numbre of documents created, not created, with warning, etc; and when the user press two times the apropiated icon , the program will display the corresponding documents).

I have never made this, if this Log is a Dialog Screen, i could put buttons in the screen and execute an action; but i do not know how to set buttons (icons) in a Report List body and execute an action when the user press that icons (one click or two clicks, whatever).

Does some body can help me, how can i achieve this ?

Regards

Frank

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Jan 10, 2007 at 06:14 PM

    You can make use of something called as HOT SPOT in ALV reporting.

    The steps you follow is

    1. in the field catalog you mark that field as hot spot. i,e, ls_fieldcatalog-hotspot = 'X'.

    2. You capture the handle. i.e the field the double click was made.

    3. Based on that you do a call transaction to open the document.

    Below is and example.

    IF ls_fieldcatalog-fieldname = 'LABST'.

    ls_fieldcatalog-hotspot = 'X'.

    ENDIF.

    by using this i can have the hotspot ..but with undeline, But the problem

    is when i double click on new object is not creating even its not going into debug mode.

    can any one help me in this.

    here is my double clicking code, what i have to do after defining hotspot click event.

    CLASS lcl_event_receiver DEFINITION.

    PUBLIC SECTION.

    METHODS:

    **Hot spot Handler

    • HANDLE_HOTSPOT_CLICK FOR EVENT HOTSPOT_CLICK OF CL_GUI_ALV_GRID

    • IMPORTING E_ROW_ID E_COLUMN_ID ES_ROW_NO,

    *

    handle_double_click

    FOR EVENT double_click OF cl_gui_alv_grid

    IMPORTING e_row e_column,

    .

    ENDCLASS.

    METHOD handle_double_click.

    READ TABLE imain INTO wa_imain INDEX e_row-index.

    IF e_column = 'LABST' AND NOT wa_imain-labst IS INITIAL.

    CLEAR w_matnr.

    CLEAR wa_matnr.

    w_matnr = wa_imain-matnr.

    CONCATENATE 'Unrestricted Stock For Material ' w_matnr INTO

    wa_matnr.

    SELECT mard~matnr

    mard~werks

    SUM( mard~labst ) AS labst

    INTO TABLE itab FROM mard WHERE matnr = wa_imain-matnr

    GROUP by mardmatnr mardwerks.

    • ENDIF.

    DELETE itab WHERE labst = '0'.

    IF dialogbox_status IS INITIAL.

    dialogbox_status = 'X'.

    w_flag = 'X'.

    PERFORM create_summary_detail.

    ELSE.

    PERFORM create_summary_detail1.

    CALL METHOD dialogbox_container->set_visible

    EXPORTING visible = 'X'.

    • CALL METHOD grid2->refresh_table_display.

    ENDIF.

    ENDIF.

    ENDMETHOD.

    METHOD handle_close.

    CALL METHOD sender->set_visible

    EXPORTING visible = space.

    ENDMETHOD.

    - Guru

    Reward points for helpful answers

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 10, 2007 at 06:08 PM

    https://forums.sdn.sap.com/click.jspa?searchID=686222&messageID=1467690

    https://forums.sdn.sap.com/click.jspa?searchID=686222&messageID=825026

    hi check the above links they will guide you, if u want this report to act as a interactive then u can do regular programming for making the icons acting to Double Click

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 10, 2007 at 06:16 PM

    hi,

    lok at the report DEMO_DYNPRO_STATUS_ICONS

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.