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

reg. push buttons

Former Member
0 Likes
737

HI Friends,

How to create pushbuttons in ALV Reports?.Rewards are helpful.

Thanks & Regards,

Narasimha Rao.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
720

Hi,

If you want create pushbuttons in Apllication Tool bar in ALV Report.

First create PF Status with required buttons in Application ToolBar.

1. For ALV Function modules.

create a subroutine with name SET_PF_STATUS.

in that subroutine you declare the PF status.

-


call function 'REUSE_ALV_GRID_DISPLAY'

exporting

i_callback_program = gd_repid

i_callback_top_of_page = 'TOP-OF-PAGE'

i_callback_pf_status_set = 'SET_PF_STATUS' "see FORM

is_layout = gd_layout

it_fieldcat = fieldcatalog[]

i_save = 'X'

tables

t_outtab = it_ekko

exceptions

program_error = 1

others = 2.

-


FORM SET_PF_STATUS *

-


FORM set_pf_status USING rt_extab TYPE slis_t_extab.

SET PF-STATUS 'ZNEWSTATUS'.

"Copy of 'STANDARD' pf_status from fgroup SALV

ENDFORM.

2.For ALV Methods.

call screen 100.

in the process before output, call pf status

Process before output.

SET PF-STATUS 'ZNEWSTATUS'.

Hope this solve your problem.

Reward points .

5 REPLIES 5
Read only

Former Member
0 Likes
720

If you mean within the report, have a look at

http://help.sap.com/saphelp_erp2004/helpdata/en/88/387f380c2f2e3ce10000009b38f8cf/frameset.htm

If you want buttons on the main menu toolbar, then the PF-STATUS needs to be defined.

Jonathan

Read only

Former Member
0 Likes
721

Hi,

If you want create pushbuttons in Apllication Tool bar in ALV Report.

First create PF Status with required buttons in Application ToolBar.

1. For ALV Function modules.

create a subroutine with name SET_PF_STATUS.

in that subroutine you declare the PF status.

-


call function 'REUSE_ALV_GRID_DISPLAY'

exporting

i_callback_program = gd_repid

i_callback_top_of_page = 'TOP-OF-PAGE'

i_callback_pf_status_set = 'SET_PF_STATUS' "see FORM

is_layout = gd_layout

it_fieldcat = fieldcatalog[]

i_save = 'X'

tables

t_outtab = it_ekko

exceptions

program_error = 1

others = 2.

-


FORM SET_PF_STATUS *

-


FORM set_pf_status USING rt_extab TYPE slis_t_extab.

SET PF-STATUS 'ZNEWSTATUS'.

"Copy of 'STANDARD' pf_status from fgroup SALV

ENDFORM.

2.For ALV Methods.

call screen 100.

in the process before output, call pf status

Process before output.

SET PF-STATUS 'ZNEWSTATUS'.

Hope this solve your problem.

Reward points .

Read only

Former Member
0 Likes
720

Hi,

ALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'

EXPORTING

i_callback_program = ws_repid

i_callback_pf_status_set = 'GUI_STAT1'

i_callback_user_command = 'STAT'

is_layout = gs_layout

it_fieldcat = i_fieldcat[]

it_sort = wa_sort1

TABLES

t_outtab = i_zaw_pol_plan.

IF sy-subrc <> 0.

  • MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno

  • WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.

ENDIF.

FORM gui_stat1 USING rt_extab TYPE slis_t_extab.

SET PF-STATUS 'STANDARD1' EXCLUDING rt_extab.

SET TITLEBAR text-005.

ENDFORM.

double click on 'STANDARD1' expand the application toolbar add buuton Fcode ,Icon .

Read only

Former Member
0 Likes
720

Hi,

it is possible in SALV. Try it

L.Velu

Read only

Former Member
0 Likes
720

If you want create pushbuttons in Apllication Tool bar in ALV Report.

First create PF Status with required buttons in Application ToolBar.

1. For ALV Function modules.

create a subroutine with name SET_PF_STATUS.

in that subroutine you declare the PF status.

-


call function 'REUSE_ALV_GRID_DISPLAY'

exporting

i_callback_program = gd_repid

i_callback_top_of_page = 'TOP-OF-PAGE'

i_callback_pf_status_set = 'SET_PF_STATUS' "see FORM

is_layout = gd_layout

it_fieldcat = fieldcatalog[]

i_save = 'X'

tables

t_outtab = it_ekko

exceptions

program_error = 1

others = 2.

-


FORM SET_PF_STATUS *

-


FORM set_pf_status USING rt_extab TYPE slis_t_extab.

SET PF-STATUS 'ZNEWSTATUS'.

"Copy of 'STANDARD' pf_status from fgroup SALV

ENDFORM.

2.For ALV Methods.

call screen 100.

in the process before output, call pf status

Process before output.

SET PF-STATUS 'ZNEWSTATUS'.

Hope this solve your problem.

Reward points if useful.