2009 Mar 16 11:36 AM
hi all,
I have created a pf status in se41 for my ALV prog. where should i use this in my program..
your help will be greatly appreciated.
2009 Mar 16 11:39 AM
Hi,
you have to use in the PBO of screen in that progrom...
like below
set pf-status 'WYSV_STATUS'.
Thanks!
2009 Mar 16 11:41 AM
2009 Mar 16 11:41 AM
Hi,
The PF status is created for custom-screen in the prog.
Use the PF status with commant SET PF-STATUS, just before you beging to write in the list.
Usually, this is the first command in the End of selection event
Thanks,
RJ
2009 Mar 16 11:45 AM
Hi,
Use this as follows:
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
I_CALLBACK_PROGRAM = SY-REPID
I_CALLBACK_PF_STATUS_SET = 'F_STATUS' "<-- routine name
I_CALLBACK_USER_COMMAND = 'USER_COMMAND'
IT_FIELDCAT = GT_FIELDCAT[]
IT_EVENTS = EVENT[]
TABLES
T_OUTTAB = IT_FINAL[]
FORM F_STATUS USING P_extab TYPE slis_t_extab.
SET PF-STATUS 'STANDARD'.
ENDFORM.
2009 Mar 16 11:46 AM
Hi,
write the below code in your se38 pgm
set pf-status 'ZSTATUS' and double click on status name then it leades to another screen saying that application tool bar, menu bar and function code. and do what ever thenfinally acitvate
Finally you need to pass the Pf-status into the ALV_LIST_DISPALY or ALV_GRID_DISPLAY functtion module. then it will be visible to your program when the program dispays the output
Thanks
Ramakrishna Pathi
2009 Mar 16 11:56 AM
Hi Sunitha
look tis link,it had explained you with example and screen shots about ALV.
[https://wiki.sdn.sap.com/wiki/display/ABAP/OBJECTORIENTEDALV+Guide]
Regards
Hareesh Menon
2009 Mar 16 12:13 PM
Hi,
Refer this program:-
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = v_rep_id " report id
i_callback_pf_status_set = 'PF' " for PF-STATUS
it_fieldcat = it_field " field catalog
TABLES
t_outtab = it_final " internal table
EXCEPTIONS
program_error = 1
OTHERS = 2.
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 pf
*&---------------------------------------------------------------------*
* SUB-ROUTINE PF IS USED TO SET THE PF-STATUS OF THE SCREEN
* ON WHICH THE ALV GRID IS DISPLAYED
*----------------------------------------------------------------------*
* -->RT_EXTAB
*----------------------------------------------------------------------*
FORM pf USING rt_extab TYPE slis_t_extab.
SET PF-STATUS 'ZTG_STAT'.
ENDFORM. "pf
For reference you can check wiki code by me:-
Learn to display data in ALV Grid
Hope this helps you.
Regards,
Tarun
2009 Mar 16 12:20 PM
Hi Sunitha,
For Creating the pf-status for the function module:
REUSE_ALV_GRID_DISPLAY
FORM pf_status USING rt_extab TYPE slis_t_extab.
SET PF-STATUS 'FIRST'.
ENDFORM. "PF_STATUS
FORM comm USING ucomm LIKE sy-ucomm selfield TYPE slis_selfield.
DATA: okcode TYPE sy-ucomm.
okcode = ucomm.
CASE okcode.
WHEN 'REF'.
CALL FUNCTION 'POPUP_TO_INFORM'
EXPORTING
titel = 'MANSI'
txt1 = 'CREATED BY'
txt2 = SY-UNAME
* TXT3 = ' '
* TXT4 = ' '
.
endcase.
And then in the function module,Reuse_alv_grid_display pass these
subroutines in their parameters:
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_INTERFACE_CHECK = ' '
I_BYPASSING_BUFFER = ' '
I_BUFFER_ACTIVE = ' '
i_callback_program = sy-repid
i_callback_pf_status_set = 'PF_STATUS'
i_callback_user_command = 'COMM'
Hope it helps
Regrds
Mansi
2009 Mar 16 1:27 PM
In FM REUSE_ALV_GRID_DISPLAY
Set the parameter
i_callback_pf_status_set = 'PF_STATUS_SET'
Then
*FORM pf_status_set USING rt_extab TYPE slis_t_extab.
SET PF-STATUS 'ZSTANDARD' OF PROGRAM <your program name>.
ENDFORM.* "pf_status_set
Thanks.
2009 Mar 17 3:38 AM
HI All,
Thank you for helping me out in this issue..
Now, I have created on icon.My requirement is that if i select / press that icon, internal table must be popup as an output. how is it possible? please help me in this regard.
thanking you
2009 Mar 17 5:25 AM
Hi
Now you set the parameter i_callback_user_command = 'USER_COMMAND' of
FM REUSE_ALV_GRID_DISPLAY.
Now create a subroutine like the following one:
FORM user_command USING I_r_ucomm LIKE sy-ucomm
rs_selfield TYPE slis_selfield.
CASE I_r_ucomm.
WHEN 'ITAB'. " assuming it is the Fcode you've assigned on your button
CALL FUNCTION 'POPUP_WITH_TABLE_DISPLAY'
EXPORTING
ENDPOS_COL = 68
ENDPOS_ROW = 66
STARTPOS_COL = 1
STARTPOS_ROW = 1
TITLETEXT = 'Testing'
IMPORTING
CHOISE =
TABLES
VALUETAB = <your itab name>
EXCEPTIONS
BREAK_OFF = 1
OTHERS = 2
.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM.
Hope it solve your problem.
Regards.
Sarbajit
Edited by: Sarbajit Majumdar on Mar 17, 2009 10:56 AM
Edited by: Sarbajit Majumdar on Mar 17, 2009 10:57 AM
2009 Mar 17 5:33 AM
Hi sunitha
use this statement
CALL SCREEN <SCREEN_NUMBER> STARTING AT 10 10.
Regards
Hareesh Menon
2009 Mar 17 5:37 AM
Try this code,
FORM pf_status USING rt_extab TYPE slis_t_extab.
SET PF-STATUS 'Z_STATUS'.
ENDFORM.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = v_repid
i_callback_pf_status_set = 'PF_STATUS'
it_fieldcat = it_field
TABLES
t_outtab = i_final
EXCEPTIONS
program_error = 1
OTHERS = 2.
Regards,
Joan
2009 Mar 18 5:08 AM
2009 Mar 18 6:02 AM