Application Development 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: 

PF status of Selection screen and ALV Grid

Former Member
0 Kudos

Hi,

I need to create a report where on clicking the<b> 'ENTER'</b> key on application toolbar on the <b>selection-screen</b> the processing logic should get executed ( instead of clicking execute pushbutton).

For this i need to capture the function code associated with ENTER key on selection screen. How can i find this?

Also , on clicking enter i have to display <b>an ALV grid</b> with the <b>SAVE</b> key activated on the toolbar.How can i activate SAVE key on application toolbar of ALV GRID. (<b>Selection-screen should not have save key</b> )

thanks,

vartika

4 REPLIES 4

RichHeilman
Developer Advocate
Developer Advocate
0 Kudos

To answer your first question, you can do something like this.



REPORT  ZRICH_0001.

tables: sscrfields.


parameters: p_check.

at selection-screen.

  if sscrfields-ucomm = space.
      sscrfields-ucomm = 'ONLI'.
  endif.

  start-of-selection.

   write:/ 'Start of Selection has been executed'.

Regards,

Rich Heilman

0 Kudos

Thanks a lot Rich, it solved the problem.

Any suggestions for the second Question?

vartika

Former Member
0 Kudos

Hi

you can just copy the alv standard pf status into your alv.

goto se41.

enter "SAPLSLVC_FULLSCREEN"

then copy the standard pf status " STANDARD_FULLSCREEN" to your program "xyz".

in your prog, when you call the alv grid,

CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'

EXPORTING

  • I_INTERFACE_CHECK = ' '

  • I_BYPASSING_BUFFER = ' '

  • I_BUFFER_ACTIVE = ' '

i_callback_program = l_v_repid

i_callback_pf_status_set = 'SET_PF_STATUS' <----


i_callback_user_command = 'USER_COMMAND'

i_callback_top_of_page = 'ALV_TOP_OF_PAGE'

  • I_CALLBACK_HTML_TOP_OF_PAGE = ' '

tHEN CPOY PASTE THIS CODE:

NOTE: No need to make a perform for this....

*------------------------------------------------------------------*
*       FORM SET_PF_STATUS                                         *
*------------------------------------------------------------------*
FORM set_pf_status USING rt_extab TYPE slis_t_extab.
  SET PF-STATUS '/FIR/RRF2S0BG_ALV'.
  "Copy of standard pf_status from
ENDFORM.                    "set_pf_status

Now can see the full tool bar enabled in your alv grid.

delete all the unwanted buttons from your programs pf status .

Hope that helps.

Cheers

Ravish Garg.

<i>

Reward if useful</i>

Former Member
0 Kudos

Hi Vartika,

Try This.

SET PF-STATUS 'STATUS01'.

1. Double click on status01.

2. In the FunctionKeys - > Standard Tool Bar -> type SAVE above the save Icon

Reward If Useful.

Regards,

Chitra