Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

ALV Treee (CL_GUI_ALV_TREE) hot spot functionality

Former Member
0 Likes
1,953

Hi,

I am displaying the data using CL_GUI_ALV_TREE at 3 node levels. When I click on one of the column(hotspot column) it should navi gate to some other scrreen to display some log information.

How could we transport the data from this ALV tree screen to second screen.

Already mention the hotspot = x in filed catalogue

and item_selection = 'X' when creating the tree control..

Also when I have clicked on the hotspot its not triggring , I have used the event METHODS handle_item_double_click

FOR EVENT item_double_click OF cl_gui_alv_tree

IMPORTING node_key fieldname.

Do we need to assign the function code for this hotspot?

Can you please suggest how can we trigger the hotspot and need to navi gate to seond screen.

Thanks in advance.

Best Regards,

Kishore

Hi,

I am displaying the data using CL_GUI_ALV_TREE at 3 node levels. When I click on one of the column(hotspot column) it should navi gate to some other scrreen to display some log information.

How could we transport the data from this ALV tree screen to second screen.

Already mention the hotspot = x in filed catalogue

and item_selection = 'X' when creating the tree control..

Also when I have clicked on the hotspot its not triggring , I have used the event METHODS handle_item_double_click

FOR EVENT item_double_click OF cl_gui_alv_tree

IMPORTING node_key fieldname.

Do we need to assign the function code for this hotspot?

Can you please suggest how can we trigger the hotspot and need to navi gate to seond screen.

Thanks in advance.

Best Regards,

Kishore

5 REPLIES 5
Read only

Former Member
0 Likes
1,175

hotspot is 1 click and u have used double click event. So are clicking the item once or twice??

did u set the handler for the event ??

you need to set the handler too before displaying your tree.

use keyword Set handller

Hope this will help!!!

Thanks

Read only

0 Likes
1,175

Hi,

Thank you for your reply. I have used the set handler event but its not triggering. Can you pleae let me know the options available for triggering hotspot click.

Thanks,

kishore

Read only

0 Likes
1,175

Please refer standard program BCALV_TREE_02 . You will see how to register and handle the events for tree correctly.

Regards

Marcin

Read only

naimesh_patel
Active Contributor
0 Likes
1,175

As Marcin mentioned, you need to register the TREE events properly.

Something like:


    DATA: lt_events TYPE cntl_simple_events,
          l_event TYPE cntl_simple_event.

    CALL METHOD g_alv_tree->get_registered_events
      IMPORTING
        events = lt_events.

    l_event-eventid = cl_gui_column_tree=>EVENTID_ITEM_DOUBLE_CLICK.
    APPEND l_event TO lt_events.

    CALL METHOD g_alv_tree->set_registered_events
      EXPORTING
        events                    = lt_events
      EXCEPTIONS
        cntl_error                = 1
        cntl_system_error         = 2
        illegal_event_combination = 3.

Regards,

Naimesh Patel

Read only

Clemenss
Active Contributor
0 Likes
1,175

Hi Jacks,

try to register your handler for event LINK_CLICK.

Regards,

Clemens