05-22-2014 3:12 PM
Hi All,
For making all the rows of a column as hotspot in ALV , we select the field catalogue attribute hotspot = 'X'
However in my requirement I want some of the records in 1 column as hotspot and the other without hotspot .
How can we achieve this???
Thanks,
Faiz
05-22-2014 3:27 PM
Hi,
Which one your using reuse_alv_grid_display or OO ALV?
Thanks,
Ashok.
05-22-2014 3:36 PM
Hi Faizur,
What you can do is at the time of handling the hotspot clicks, skip (do nothing) the records which you don't want to navigate for. i.e. in User Command where you handle the navigation, exclude based on condition over there.
Hope that helps.
Regards,
Naveen
05-23-2014 9:54 AM
Hi faizur,
Set the hotspot = 'X' in the field catalog for that particular field and assuming that you are using OOPS-ALV, use 'hotspot_click' event to write the logic just as mentioned by Naveen.
05-23-2014 10:46 AM
Hi Faizur,
If you use CL_GUI_ALV_GRID or REUSE_ALV_GRID_DISPLAY_LVC you can manage single cells styles.
To do this you need to add a type table for Styles in your ALV structure:
TYPES: BEGIN OF t_st_alv,
...
styletab TYPE lvc_t_styl,
END OF t_st_alv.
Define Layout with the name of Style Field:
gst_layout-stylefname = 'STYLETAB'.
Add style to desidered cell:
DATA: lst_styletab TYPE lvc_s_styl,
FIELD-SYMBOLS: <fs_st_alv> TYPE t_st_alv.
LOOP AT gtb_alv ASSIGNING <fs_st_alv>.
IF...
lst_styletab-fieldname = "FieldName where you want to set Style".
lst_styletab-style = cl_gui_alv_grid=>mc_style_hotspot. "Hotspot Style
INSERT lst_celltab INTO TABLE <fs_st_alv>-styletab.
ENDIF.
ENDLOOP.
Regards,
Angelo.