2010 Mar 15 7:16 PM
Hi,
I want to add a custom button on ALV in application toolbar. I have created the ALV using 'REUSE_ALV_GRID_DISPLAY' FM. Can I achieve this using the same function module or I have to use OO mechanism(like set_table_for_first_display)... and then create the button on screen(using SE51)
Thanks,
Edited by: WDAbap on Mar 15, 2010 9:10 PM
2010 Mar 15 8:38 PM
Hi
Just copy standard PF-STATUS to new one,add any button you want and call this new PF-STATUS in your function.
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_callback_program = gd_repid
i_callback_pf_status_set = 'SET_PF_STATUS' -
> go to form defined by you
is_layout = gd_layout
it_fieldcat = fieldcatalog[]
tables
t_outtab = it_mara
exceptions
program_error = 1
others = 2.
***********************************
FORM SET_PF_STATUS *
**********************************
FORM set_pf_status USING rt_extab TYPE slis_t_extab.
SET PF-STATUS 'ZNEWST'.
"Copy of 'STANDARD' status from FG SALV
ENDFORM.
Best Regards
Yossi Rozenberg
Hi,
I want to add a custom button on ALV in application toolbar. I have created the ALV using 'REUSE_ALV_GRID_DISPLAY' FM. Can I achieve this using the same function module or I have to use OO mechanism(like set_table_for_first_display)... and then create the button on screen(using SE51)
Thanks,
Edited by: WDAbap on Mar 15, 2010 9:10 PM
2010 Mar 15 8:38 PM
Hi
Just copy standard PF-STATUS to new one,add any button you want and call this new PF-STATUS in your function.
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_callback_program = gd_repid
i_callback_pf_status_set = 'SET_PF_STATUS' -
> go to form defined by you
is_layout = gd_layout
it_fieldcat = fieldcatalog[]
tables
t_outtab = it_mara
exceptions
program_error = 1
others = 2.
***********************************
FORM SET_PF_STATUS *
**********************************
FORM set_pf_status USING rt_extab TYPE slis_t_extab.
SET PF-STATUS 'ZNEWST'.
"Copy of 'STANDARD' status from FG SALV
ENDFORM.
Best Regards
Yossi Rozenberg
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |