ALV Report - call transaction using Hot spot
Hotspots are special areas of an output list. If the user clicks once onto a hotspot field, an event is triggered. This article ALV Report - call transaction using Hot spot shows how it can be done.
For inserting the Hotspots in the ALV, we need to follow following steps in ALV:

1. In the fieldcatalog you will have to write the hotspot as shown below:
wa_fieldcat-hotspot = ‘X’.
APPEND wa_fieldcat TO it_fieldcat.
CALL FUNCTION ‘REUSE_ALV_GRID_DISPLAY’
EXPORTING
i_callback_program = sy-repid
i_callback_user_command = ‘USER_COMMAND’“—-> this is important
- i_callback_pf_status_set = ‘PFSTATUS’
it_fieldcat = it_fieldcat
is_layout = it_layout
- it_event_exit = it_eventexit
- i_screen_start_column = 10
- i_screen_start_line = 20
- i_screen_end_column = 70
- i_screen_end_line = 45
i_grid_title = ‘Customer-Order Details’
TABLES
t_outtab = it_data.
2. Then we have to catch this User Command as follows :
FORM user_command USING r_ucomm TYPE sy-ucomm
rs_selfield TYPE slis_selfield.
DATA: alv_vbeln TYPE vbeln,
mess_text(30) TYPE c,
txt_vbeln(10) TYPE c.
*User clicks a Order No. in ALV it passed to the following transaction.
CASE r_ucomm.
WHEN ‘&IC1’.
READ TABLE it_data INDEX rs_selfield-tabindex INTO wa_data.
alv_vbeln = wa_data-vbeln..
IF sy-subrc = 0.
CLEAR: mess_text, txt_vbeln.
SUBMIT zprogram
WITH pr_vbeln = alv_vbeln AND RETURN. “put your call transaction logic here
ENDIF.
ENDCASE.
ENDFORM. “user_command
Other related tutorial can be - ALV generation using Object Oriented way can also be done in 3 steps - ABAP Program for Creating an ALV Grid in 3 lines.












Hello:
I am using ALV OO event DOUBLE_CLICK, and I am calling the transaction as follows:
SET PARAMETER ID ‘AUN’ FIELD wa_orders-aufnr.
CALL TRANSACTION ‘IW39’ AND SKIP FIRST SCREEN.
My problem is when I double click the Order Number in the ALV, it goes to the IW39 transaction, but no value is sent to the order number field.
Do you know what could be happening?
Thanks in advance.
Regards,
Tere.
Hello,
i am getting a dump when i enter my layout(TYPE LVC_S_LAYO) and fieldcatalog(type LVC_T_FCAT) into the function.
Could u show ur DATA declaration please?
Regards,
Wayne