Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

ALV - hotspot

Dear friends,

Used object oriented abap for the first time in a report and for alv as well.

Objects columns TYPE REF TO cl_salv_columns_table and column TYPE REF TO cl_salv_column_table are used insted of fieldcatalog.

But not able find any property for hotspot. Is this ( column->set_hyperlink_entry( ) ) meant for hotspot ?.

Kindly suggest,

Praveen Lobo

replied

For HOTSPOT you need to get the Columns first and than get the Column property and set the HOTSPOT useing the SET_CELL_TYPE.

Like:

*...Columns tables for the HotSpot.........................................
    DATA: LO_COLS_TAB TYPE REF TO CL_SALV_COLUMNS_TABLE,
          LO_COL_TAB  TYPE REF TO CL_SALV_COLUMN_TABLE.

*   get Columns object
    LO_COLS_TAB = O_ALV->GET_COLUMNS( ).

*   Get VBELN column
    TRY.
        LO_COL_TAB ?= LO_COLS_TAB->GET_COLUMN( 'VBELN' ).
      CATCH CX_SALV_NOT_FOUND.
    ENDTRY.

*   Set the HotSpot for VBELN Column
    TRY.
        CALL METHOD LO_COL_TAB->SET_CELL_TYPE
          EXPORTING
            VALUE = IF_SALV_C_CELL_TYPE=>HOTSPOT.
        .
      CATCH CX_SALV_DATA_ERROR .
    ENDTRY.

Regards,

Naimesh Patel

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question