cancel
Showing results for 
Search instead for 
Did you mean: 

Hyperlink in ALV Header

Former Member
0 Kudos

Hello Experts,

I am developing a dynamic ALV report. Can we have a hyperlink in the ALV header ?

Thanks

Vivek

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Vivek,

I don't think you can have hyperlink in ALV header.because the class CL_SALV_WD_HEADER provide method to Set text.

But another option would be create a LTA as a toolbar item.

Thanks,

Sowmya

Former Member
0 Kudos

Hi Sowmya,

Thanks for your reply. But my requirement is not just to have a single hyperlink in the header. I want all my column header to be displayed as hyper link. So when the user clicks on the link i will display some popup information.

Thanks,

Vivek

Former Member
0 Kudos

HI Vivek,

     you can not createa LTA in the header as in header you can only set some text & provide some image to display . If you cannot achive ur goal by using toolbar & above req is must for u then create an entry as LTA in table content with index 1, before display .

Regards,

Monishankar Chatterjee

Former Member
0 Kudos

Hi Shankar,

Thanks for your reply.

Actually i display photos in all the cells of the ALV table, So in column settings i use the code below.

Is it possible to display photo in first row and LTA in second row of the same column?

Code Sample:

data:   lr_input_field   TYPE REF TO cl_salv_wd_uie_link_to_action,

          lv_field type string value 'http://........'.

   LOOP AT lt_columns INTO ls_columns.

 

   CREATE OBJECT lr_input_field.

  ls_columns-r_column->set_cell_editor( lr_input_field ).

  lr_input_field->set_image_source( lv_field ).

  ENDLOOP.

Thanks

Vivek

Former Member
0 Kudos

Hyperlink on alv column header is not possible. I guess it is available in higher versions. NW 7.0 onwards.

You can do this way:

Provide LTA to the 1st row and there is a method in LTA set_image_source of CL_SALV_WD_UIE_LINK_TO_ACTION where you can see both image and a hyperlink.

Hope this meets your requirement.

Former Member
0 Kudos

Hi Lekha,

Thanks for your reply.

I am using SAP_BASIS 701 release. Support level package 12. Still i can use hyper link in ALV column header?

Yes currently i am using the CL_SALV_WD_UIE_LINK_TO_ACTION class to display my photo and LTA in the same cellof my ALV output. My requirement is to perform different action when i click on photo and LTA respectively. Now when i click the photo and the LTA, same column id is getting imported in the ON_CLICK event of the ALV output. So i created two columns now to display the LTA and photos separately to get different column id in ON_CLICK event. However the output does not look good since the LTA have different header and photo have a different header. Is there any way we can merge the cells in the ALV output.

Thanks,

Vivek

Former Member
0 Kudos

Hi Vivek,

Please check if this thread helps you:

http://scn.sap.com/message/10188027#10188027

thanks,

Sowmya

Former Member
0 Kudos

Hi Vivek !

  

     I dont think even in 7.01 you have the same facility . Also for ur requirement u can use 'MultiEditorCell' UI using cell variant but thats fits with table. There will not be any option to add image & LTA ( as cell editors permitted for this is limited ) but u can add a button with image & LTA if u want.

    Again for ALV I dont think this option is available in netweaver 7.01.

for details information check below :-

http://scn.sap.com/thread/1763580

https://help.sap.com/erp2005_ehp_06/helpdata/zh/f8/ec79aeacca4f94a17d167abbaa0490/frameset.htm

Regards,

Monishankar

Former Member
0 Kudos

Hi Thanks Everyone...

I have resolved my issue using cell variants...