cancel
Showing results for 
Search instead for 
Did you mean: 

WHAT ARE THE PBO AND PAI EVENTS IN REPORTING

Former Member
0 Kudos

hi all,

WHAT ARE THE PBO AND PAI EVENTS IN REPORTING

and module pool

regards,

anilreddy

Accepted Solutions (1)

Accepted Solutions (1)

RichHeilman
Developer Advocate
Developer Advocate

In reporting the PBO is AT SELECTION-SCREEN OUTPUT. and the PAI is AT SELECTION-SCREEN.

Regards,

RIch Heilman

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

<b>REPORTS</b>

In the PBO of the selection screen, the

AT SELECTION-SCREEN OUTPUT

event is triggered. This event block allows you to modify the selection screen directly before it is displayed.

PARAMETERS: TEST1(10) MODIF ID SC1,

TEST2(10) MODIF ID SC2,

TEST3(10) MODIF ID SC1,

TEST4(10) MODIF ID SC2.

AT SELECTION-SCREEN OUTPUT.

LOOP AT SCREEN.

IF SCREEN-GROUP1 = 'SC1'.

SCREEN-INTENSIFIED = '1'.

MODIFY SCREEN.

CONTINUE.

ENDIF.

IF SCREEN-GROUP1 = 'SC2'.

SCREEN-INTENSIFIED = '0'.

MODIFY SCREEN.

ENDIF.

ENDLOOP.

The AT SELECTION-SCREEN event is triggered in the PAI of the selection screen once the ABAP runtime environment has passed all of the input data from the selection screen to the ABAP program. If an error message occurs in this processing block, the selection screen is redisplayed with all of its fields ready for input. This allows you to check input values for consistency.

The program below is connected to the logical database F1S:

REPORT EVENT_DEMO.

NODES SPFLI.

AT SELECTION-SCREEN.

IF CARRID-LOW IS INITIAL

OR CITY_FR IS INITIAL

OR CITY_TO IS INITIAL.

MESSAGE E000(HB).

ENDIF.

<b>MODULEPOOL</b>

PROCESS BEFORE OUTPUT (PBO) is automatically triggered after the PAI processing of the previous screen and before the current screen is displayed. You can program the PBO processing of the screen in this block. At the end of the PBO processing, the screen is displayed.

PROCESS AFTER INPUT (PAI) is triggered when the user chooses a function on the screen. You can program the PAI processing of the screen in this block. At the end of the PAI processing, the system either calls the next screen or carries on processing at the point from which the screen was called.

PROCESS ON HELP-REQUEST (POH) and PROCESS ON VALUE-REQUEST (POV) are triggered when the user requests field help (F1) or possible values help (F4) respectively. You can program the appropriate coding in the corresponding event blocks. At the end of processing, the system carries on processing the current screen.

Regards,

Ravi

Former Member
0 Kudos

PAI:

When ever some user actions takes place like SAVE, DELETE, SUBMIT etc.,, you capture the function code and write your code here.

PBO:

Just remember that PBO will be processed before the screen is displayed to the end user.

Dont have myth that select statements are always written in PBO. Nothing like that. Everything depends up on your requirements.