04-30-2008 8:53 AM
Hello to all,
I want to display a purchase order in an ALV Grid with its details,
and user can see the other purchase order by clicking the Next, Previous, First and Last button Application toolbar.
I have all the data(PO with there details) in an Internal table.
How i can achieve the navigation of PO in the grid using the above stated buttons.
Regards
Saurabh
04-30-2008 11:29 AM
Hi,
You can use pf-status to navigate display another purchase order.
FORM set_pf_status USING rt_extab TYPE slis_t_extab.
SET PF-STATUS 'xxxxxx'.
ENDFORM.
This is the standard subroutine for handling pf-status.
you have to pass this subroutine name to pf-status in grid display.
I_CALLBACK_PF_STATUS_SET = 'SET_PF_STATUS'
After that you have to use the user-command subroutine to handle the function codes.
FORM USER_COMMAND USING UCOM TYPE SY-UCOMM R_SELFIELD TYPE SLIS_SELFIELD.
CASE UCOM.
WHEN 'NEXT'.
leave to list-processing.
-
-
WHEN 'PREVIOUS'.
leave to list-processing.
-
-
ENDCASE.
endform.
Then you have to pass this usercommand subroutine to your grid display.
I_CALLBACK_USER_COMMAND = 'USER_COMMAND'
I think it is helpful for you.