2007 Jul 11 7:15 AM
hi, all
How can I add the button to toolbar for the OO ALV?
Thanks for your help!
2007 Jul 11 7:19 AM
check the program BCALV_GRID_VERIFY
This will be really helpfull for the same...
in class definition
methods handle_toolbar_set
for event toolbar of cl_gui_alv_grid
importing e_object e_interactive.
method handle_toolbar_set.
handle toolbar
create own Menubuttons and ToolbarButtons
if e_interactive is initial.
clear gs_toolbar.
move 'DELE' to gs_toolbar-function.
move icon_delete to gs_toolbar-icon.
move 'Mein Löschen'(111) to gs_toolbar-quickinfo.
move ' ' to gs_toolbar-disabled.
append gs_toolbar to e_object->mt_toolbar.
clear gs_toolbar.
move 'REFR' to gs_toolbar-function.
move icon_refresh to gs_toolbar-icon.
move 'Mein Refresh'(112) to gs_toolbar-quickinfo.
move ' ' to gs_toolbar-disabled.
insert gs_toolbar into e_object->mt_toolbar index 1.
endmethod..
Implementatioon
set handler event_receiver->handle_toolbar_set for grid1.
2007 Jul 11 7:19 AM
check the program BCALV_GRID_VERIFY
This will be really helpfull for the same...
in class definition
methods handle_toolbar_set
for event toolbar of cl_gui_alv_grid
importing e_object e_interactive.
method handle_toolbar_set.
handle toolbar
create own Menubuttons and ToolbarButtons
if e_interactive is initial.
clear gs_toolbar.
move 'DELE' to gs_toolbar-function.
move icon_delete to gs_toolbar-icon.
move 'Mein Löschen'(111) to gs_toolbar-quickinfo.
move ' ' to gs_toolbar-disabled.
append gs_toolbar to e_object->mt_toolbar.
clear gs_toolbar.
move 'REFR' to gs_toolbar-function.
move icon_refresh to gs_toolbar-icon.
move 'Mein Refresh'(112) to gs_toolbar-quickinfo.
move ' ' to gs_toolbar-disabled.
insert gs_toolbar into e_object->mt_toolbar index 1.
endmethod..
Implementatioon
set handler event_receiver->handle_toolbar_set for grid1.
2007 Jul 11 7:19 AM
Hi,
go through the following thread.....
/people/vijaybabu.dudla/blog/2006/07/21/topofpage-in-alv-using-clguialvgrid
****do rewards if usefull
vijay