12-16-2005 1:39 PM
Hy! I have got an ALV created by me with ABAP objects, and I am interested in introduce personal buttons created by me, non standard butons, INSIDE the alv. In a alv, you hav buttons to sort the content, or filter, or export to an excel sheet... I want to create a new button and put it next to theese standard buttons.
Thanx!
12-16-2005 1:48 PM
Hi ,
Welcome to SDN
Here is one code sample for the same.
Hope that solves your problem.
Thanks
Kathirvel
12-16-2005 1:50 PM
Hi,
That guide by Serder will give you a lot of information about ALV.
Being new to SDN please go through the below link to award point for the helpful answers,
https://www.sdn.sap.com/irj/sdn/crphelp
Thanks
Kathirvel
12-16-2005 1:58 PM
Hi,
look sample :
I) abap BCALV_TEST_GRID_TOOLBAR
II)this:
1)
SET HANDLER event_receiver->handle_toolbar FOR grid1.
CALL METHOD grid1->set_toolbar_interactive.
2)
CLASS lcl_event_receiver DEFINITION.
PUBLIC SECTION.
METHODS:
handle_toolbar
FOR EVENT toolbar OF cl_gui_alv_grid
IMPORTING e_object e_interactive,
3)
CLASS lcl_event_receiver IMPLEMENTATION.
METHOD handle_toolbar.
* append a separator to normal toolbar
PERFORM fill_tb USING 0 'PICK' icon_te_receipts
'Beleg anzeigen' space.
APPEND ls_toolbar TO e_object->mt_toolbar.
PERFORM fill_tb USING 0 'AEND' icon_set_state
'auf Status O ändern' space.
APPEND ls_toolbar TO e_object->mt_toolbar.
4)
FORM fill_tb USING typ func icon quinfo act.
CLEAR ls_toolbar.
ls_toolbar-butn_type = typ.
ls_toolbar-function = func.
ls_toolbar-icon = icon.
ls_toolbar-quickinfo = quinfo.
ls_toolbar-disabled = act.
ENDFORM. " fill_tb
Andreas
12-16-2005 2:05 PM